How the hell do you 'know' that?
There are tons of greasy walmart managers that support this kind of reselling.
Any store reselling anything has the duty to make sure it was not tampered with in any way.
More likely the person at the returns desk just didn't check or just straight up doesn't know. Anything returned should be checked thoroughly. I recall a few years ago a local electronics chain had some scam group return a whole bunch of iPads to different locations that had been removed, the boxes filled with a bag of sand for the correct weight, and then the boxes were resealed in plastic.