This process is called sublimation. The opposite (deposition) is where a gas turns directly into a solid. Sublimation occurs if the pressure and temperature are right for the specific substance, so that the solid phase in a phase diagram borders the gas phase.
Most cicadas go through a life cycle that lasts from two to five years. Some species have much longer life cycles, such as the North American genus, Magicicada, which has a number of distinct broods that go through either a 17-year or, in some parts of the world, a 13-year life cycle.
They emerge as an adult cicada with wings, and fly away to find a mate. Once they become an adult they stop growing and do not molt again. Some of the species that take 13 or 17 years all come out of the ground at one time. There can be millions of adult cicadas flying around at that time. Some species live for 13 or 17 years and all emerge at once. Some come out every year, but nobody knows how long they spend in the ground.