Does it? I personally know several exceptions to this "rule" - and they are pretty open about it. It's not some closeted meat-eating thing.
I also personally know several counter-examples to this rule.
If meat/no-meat is the only signal people are using, there must be a lot of false positives and negatives. Or my sample of the population is somehow atypical.
Meat/no-meat is the most common signal, certainly not the only one, surname would be another, language (ethnolect or dialect) is sometimes another.
There are no perfect methods short of asking, some older people and more overtly racists (even they aren't aware) straight up do ask.
Also most racists only really care whether you are their caste or not, it doesn't matter what you actually are, so classification into their group or not is easier than do it precisely.
The thing is, there's no master text (unlike Indian constitution) that one can consult and conclude "Brahmin == no meat". Someone would cite a scripture from an ancient Hindu text (for example, Rigveda, or Manu Smriti etc.,) and draw a conclusion, however the same text might as well contain a scripture few pages down that says exactly the opposite.
Conflating the two is probably where the confusion in this thread stems from.
If some Indian were to ask me if I eat meat, I wouldn't immediately associate malice with that enquiry. Talking about food back home, is a common source of connection for a lot of the Indian diaspora.