Edit: wording
It's rarely out of malice. But that doesn't really matter. If you get asked it enough, you will start to feel like you don't belong.
As an aside, I have a last name with an unusual spelling. Literally everyone who sees it asks how it is pronounced, followed by where it is from. It is just a fact of life.
By asking the question, people clearly want to know more. Sure, they might be asking the wrong question, but the reality is, they are trying to include you.
If people didn't want you to belong, they would just make the assumption on their own and not ask (and probably avoid talking to you altogether).
"Where are you from?"
"Cleveland Heights."
"No, but like, where are you from?"
implying that this brown individual must surely have wound up from some far flung corner of the world, and that they couldn't have possibly been a native born person.
What of it? If you have some characteristic that is unusual (within a group such as local community) people will notice and be curious.
That is basic human nature, not lack of friendliness or malice.
In her case, she used the exact same vocabulary but it was much more obvious she didn't mean to imply that they weren't native born because she herself was not native. Context is important in conversation, but there is such a thing as regional mannerisms. On the west coast my vocabulary was certainly brought up for being just a tinge different.
And I'm not too fond of rural attitudes on race anywhere - if the rural west coast is somehow different, I'd love to hear your contrasting anecdotes. I know on the east coast it's certainly not the case.
Chicago, infamous MAGA country.
Where the city buses are ruled by white supremacists harassing all innocent people who look different from them!
In a city that is only 31.7% non-Hispanic white, they have a lot of work to do!
Most people in most places are basically friendly. However. Even just being recognize you as 'other' can get old, like being asked "where are you from" or riding the bus in Chicago and having to answer questions about my ethnicity from whoever was feeling tipsy enough to ask them.
Here's one story of folks being un-friendly: I was at a public event, basically a version of a county fair with my wife's family somewhere in the rural midwest. There's a stage with small-name bands performing, food vendors, and a small carnival-ride section. As the sun sets we lose track of her parents, and as we're looking for them I also got separated from my wife. I felt like the crowd was also slowly changing and like I was starting to attract attention in the form of unfriendly looks. I find my wife and try to express this, but her face clearly says it's all in my head and why am I talking about anything other than how we can find her parents. Just then a physically imposed man walks up, plants himself firmly in front of me, and asks in the least friendly way possible, "how's it going brother?" I answer him in unaccented neutral native-born american english (don't remember what i said, but likely something like "good how you doin"), and my wife is like, "ok you're right, we have to find my parents and leave."
So just to be clear - I can't know what might have been, but I strongly suspect that having grown up here and being a native speaker made that evening simpler. And again, I'm someone who many people look at and just process as "white" so I can easily take my experiences as a shallow sample from the tip of the iceberg.
And that kind of "unfriendly" experience is something that happens more often if i leave coastal metropolitan areas.