It's par for the course. Sometimes people make mistakes. Especially if you're not passing as cis. I know it sucks but realistically the majority of people have no first hand experience with trans people, when people have a lack of experience in anything, they're prone to making mistakes from time to time. As to why... who knows? Could be anything from your face, voice, body type, hand size, Adam's apple, hairline or a million other things. Just move on and don't let it bother you. Very few trans people pass as cis 100% of the time.