An elderly white (this is important) gentleman
Playing the devils advocate...
I think it behooves everyone to not see/judge people through a skin colour or even an age lens because that changes the interpretation of the encounter. Using "elderly white" or "South Asian" immediately suggests a view of the world through a filtered lens.
This says xx_. Are you xx_?
Again playing the DA...
Names tend to fit into racial and cultural stereotypes. It would be normal to assume that a South Asian person would have a South Asian name. It is also reasonable for anyone to have any type of name outside of the sterotype. For example, I have a Vietnamese colleague who has a Swedish name because she was adopted by Swedish parents as a child refugee. In the setting of aircraft boarding processes which involves a certain level of vetting, it would be reasonable to enquire whether someone is consistent with the boarding pass they are presenting especially when there is a perceived difference. It would be easy to assume that enquiry was clothed in bias/racism, but I suggest it is not as clear cut as suggested especially when security is a factor.
People will always attribute stereotypes. Be it skin colour, accent, language, appearance, age, associations, the car they drive, even their frequent flyer status. That is the nature of humanity. There is no culture/race on earth which do not express some level of racism. For example, Chinese people have a term for white people which is often construed as a racial pejorative: "Gweilo". Lounge access is another good example of bias against people who dress differently. There is a YouTuber @xiaomannyc who is a polyglot. His videos delights in showing Chinese people making assumptions that because he is white, he does not speak the various chinese dialects.
While this post is less about airplane security and more about very poor behaviour, unfortunately people do get profiled in the security context. I have another friend - this time Iranian with a beard. He tells me that he gets stopped every time at Customs and immigration. I tell him it is because he has an Iranian name and a beard. So he did an experiment and shaved. He didn't get stopped while he didn't have a beard. I'm also surprised my mother has not appeared on Channel X Border Security. She always brings in lots of food and her luggage is mostly food and gets the red lane about half of the time. At least she always ticks yes. You know the stereotype right? Now, if you know the sterotype, are you racist?
Still, the agent behaved very poorly, mabye even reprehensibly... At best she was trying to make sure that the passenger was consistent with the boarding pass as is her role at the boarding process but belittling passengers is never acceptable. At worst she was racially biased.