Well, Im not sure if any cicadas on the north american continent form pupae... I could tell if its a cicada from a picture if you have it. Most are just free moving nymphs and will remain that way until they molt into adults on the tree trunks.
If it is indeed a cidada im not sure how one would keep it alive. The nymphs eat only sap from tree roots. If its an insect (or possibly cicada) in an inactive pupae state just toss it into a container covered with some coconut husk or wood shavings, mulch, etc. keep it moist, and wait for it to molt.
Ah, in that case you will want to suspend the cocoon from a branch. possibly with a very small dab of some glue. If a moth/butterfly pupae or cocoon is left on its side sitting on the soil the insect will not form its wings correctly.