I recently posted here that I sold cars for 10 years. I can not even imagine asking someone "what can you afford?" It sounds half condescending and half way too personal/inappropriate.
People come to the dealership and ask for certain cars. Sometimes they do ask about payment ranges, and so you tell them. If they say "oh that's more than I thought, I was trying to keep it under $500 a month. Is that possible?" I tell them if it's possible via lease with $4k down or maybe on a 72 month loan. They decide. What else am I supposed to do? Go full Dave Ramsey on them and figure out if they can really afford $500 a month?
The FEW times I tried to save someone from buying an expensive used car I just KNEW would eat them alive in repairs, it was always taken very poorly, and that's with me doing it pretty tactfully in my opinion.
People that are the type to make bad financial decisions (in our opinions let's say) don't exactly take kindly to lowly 'car salesmen' implying they can't really afford something.