Once he approaches you and begins to make demands, he’d better identify himself. The whole point of the ‘resisting’ charge is that a person is resisting authority. If they don’t know they’re dealing with an authority figure, how can their behavior be considered wrong?
If I’m outside smoking a cigarette and a random person comes up to me and accuses me of smoking weed in public, then demands to examine the cigarette, I’d tell them to go to hell. If a *cop* does the same thing, I’d allow him to examine the cigarette.
I used to work in the county parks dept as a kid - I smoked Lucky Strike filterless because the summer help wouldn’t bum them - I’d twist the ends to keep the tobacco off my tongue -one day while mowing, the County Superintendent drove by - stopped his car and came over and actually removed it from my mouth just to check ,(it looked like a joint) - he never said a word - just handed it back and walked away