There's this thing called muscle memory, it means that your muscles remember how to do something even if you don't consciously (for example you know how to speak but you probably couldn't explain how to shape your mouth or situate your tongue to make a sound without sounding it out first). Older people can still remember how to drive because it is in a way muscle memory -- it is ingrained in the way their brains work. On the other hand, grocery items are just ideas buzzing in their head which can easily be pushed aside to the back of their mind and be forgotten.