The Prison key is part of the random event involving Prison Pete. It is obtained by popping one of the balloon animals. Although it has a "return" option, the player automatically walks back to Prison Pete after he tells them to. If the correct balloon animal has been popped, this key will unlock one of the barriers. If not, another barrier will be added for you to unlock. Five barriers is the maximum amount. If the key is dropped it will vanish and the player must pop another balloon animal to get a new one.
In order to get the correct key, a player must pull the lever to find out which balloon animal they should pop. They should then pop the animal that looks exactly the same as the image you see after pulling the lever. This will ensure the key fits.