We consider active particles in a heterogeneous medium, modeled by static, random obstacles. In accordance with the known tendency of active particles to cluster, we observe accumulation and crystallization of active particles around the obstacles which serve as nucleation sites. In the limit of high activity, the crystals start to rotate spontaneously, resembling a rotating rigid body. We trace the occurrence of these oscillations to the enhanced attraction of particles whose orientation points along the rotational velocity as compared to those whose orientation points in the opposite direction.