Deep down in the earth's crust, there is molten rock (magma). Molten rock is simply rocks that have melted into liquid form as a result of extreme heat under the earth. This can be found about 1800 miles deep below the surface, but closer to the surface, the rocks layers are hot enough to keep water and air spaces there at a temperature of about 50-60 degrees F (10-16 degrees C). Geothermal technology takes advantage of the hot close-to-earth-surface temperatures to generate power.
In places with hotter 'close-to-earth-surface' temperatures, deep wells can be drilled and cold water pumped down. The water runs through fractures in the rocks and is heated up. It returns to the surface as hot water and steam, where its energy can be used to drive turbines and electricity generators. (Note that there isn't any technology that allows humans to tap the heat from molten rock yet. Maybe one day, there will be)
In other places, a geothermal heat pump system consisting of pipes and pumps buried in the earth can be used to heat homes. This is done by opening up the system, extracting the hot air to feed indoor air delivery system during the cold seasons. In the USA, some geothermal systems can be found in Hawaii and Alaska.
Geothermal energy is called a renewable energy source because the water is replenished by rainfall, and the heat is continuously produced by the earth.
(More on Geothermal Energy here)