I have an unusual name so when I meet new people my brain focuses on their reaction to my name and how they pronounce it, so I completely zone out when they tell me their name. I might remember it for a short time but almost always I forgot their name if I don’t interact with them frequently.
I repeat their name back to them (helps a little, makes sure I heard right), tell them straight up l probably forget their name a couple times, and once they walk away I repeat their name a few times while trying to picture their face/anything interesting about them.
It semi works, but I’ve also let them know in advance that if I forget, it’s normal for me and not that I don’t care.
I also try to say their name often in conversation with/about them to help solidify it in my brain… But then they quit the job (most people I meet are at work, and turnover is high) and I start alllll over again with someone new. Sigh