“He’s not stealing until he’s left the building.”
Not picking on you, but that is 100% not correct.
A person can be found guilty of shoplifting if they evince an intent to steal, for instance by secreting an item, but there are other circumstances. Leaving the premises is just one possible circumstance.
I guess the elements of the crime of shoplifting vary depending on the jurisdiction, but in some places the person just has to pass the last point of purchase with an item without paying for it, and start heading for the exit. They don’t have to actually walk out of the building to be detained.