Somebody correct me if I'm wrong in any of this. I'm just seeing that this individual is looking for answers, and this is the best of my knowledge. Again, disclaimer, I'm no expert.
BUT
Stunting is illegal under a bunch of different codes (speeding, reckless driving, loitering, etc), yadda yadda... that means that at no point are you 100% safe from the law (unless you're on your own property perhaps, hmmm....). You are liable to get cited at any point.
But if you'd like to safely practice stunts, you're gonna want to find a big empty lot, just like you might have done when learning how to ride. I may or may not have used Costco parking lots in the past, after they've closed. This puts you away from traffic, away from many inanimate objects, etc. And perhaps police will look kindly upon you for taking these precautions. Meh.
Obviously, do your best to protect yourself and your bike, knowing that there's a high chance that you will drop it at some point. Again, this isn't really my area of expertise, I'm by no means an authority, and I take no responsibility for the actions of you or others. I just saw that nobody was really helping you, but hopefully that will change. Best of luck, happy stunting.