I've frozen lentils for up to a couple of months by themselves cooked in water, with stock made from smoked ham hocks or chicken broth, sometimes with stock made from lamb and bones - and onion, tomato, garlic, EVOO and herbs with no problems. They might have lasted longer ... that's just how long they lasted before I ate them! They freeze just as well as any other "bean".
Finmar001 might be confusing storing garlic in oil vs garlic cooked in a dish and frozen. Storing garlic in oil in the pantry, on the counter-top, in the refrigerator over a week or two can be a problem - frozen isn't a problem.