The police station was carved probably centuries ago, and it might have been an ancient roman tomb, since most of the carved hoodoos (Fairy chimneys) in Cappadocia are in fact ancient tombs, later converted into houses.
The eroded rock formations of Cappadocia look like sandstone, but it is actually volcanic tuff, a type of rock consisting of consolidated volcanic ash that originated from ancient volcanic eruptions in the region.
The hard stone caps on the pinnacles protected them while rains eroded the surrounding softer rock around, leaving the pointy bits behind.
The natural shape gives the building a nice watch tower as well.
There are an abundance of great architecture like this in this region so make some research before you go.