In this case, no. You would have to leave to the store, though you COULD be asked to remove the item and leave.
Let's be clear: you could very well be charged. Heck, they could charge you with exceeding the speed limit.
The question is what would happen to those charges. Clearly, the charge of exceeding the speed limit would be dropped as there is no evidence to back up that charge (and the cop could get a slap on the wrist for laying such an unwarrented charge).
The cop and the prosecutor could decide to press the charge, and see if you'll plead out. If you intend to fight the charge, they'll have to provide evidence to a Judge to back up their claims. Sometimes that evidence is circumstantial, sometimes it's forensic.
If you didn't leave the store, the shoplifting charge is much less likely to result in a conviction. But that doesn't mean you can't be charged, or that witnesses can't testify against you.
Still, the fact you were charged could cause you trouble later in life, depending on what job you want to apply for, or where you want to travel.
So it's all entirely possible. But that doesn't make it likely. Just as voters have their own agenda when they demand politicans enact various laws, police are entrusted with an agenda when it comes to enforcing them. If there is a desire to remove a nuisance from a particular neighbourhood, charges could be pursued against anyone breaking the law until there is no longer a nuisance. It's usually a simple matter to track a suspected shoplifter until there is enough evidence to warrant a conviction. For other cases, the timing may be different.
When you take part in certain activities where you might be treading in territory difficult to justify before a Judge, make sure it's not in any way causing problems for those around: neighbours whose quality of life is impacted, businesses whose customers may shy away because of what goes on.