The Deity of Fire costs no resources, and needs the Grail to be built. A hero carrying the Grail can place it in an Inferno town, thus generating the Deity of Fire. The building has tremendous power, as it increases weekly creature growth by 50%, produces 5,000 Gold per day, and causes every subsequent week to be the Week of the Imp.
The Deity of Fire has no building requirements, and it's not a prerequisite for any structure. It is possible to erect a normal building and then the Deity of Fire in the same day, but not vice-versa.