The key to using ground geothermal energy is to access ground that’s deep enough to escape the effects of surface temperatures. In many parts of the world, that’s as little as 4’ deep. Even in very cold climates, soil that maintains a steady temperature of 50°F through the seasonal cycle is typically found around 10’-12’ deep.
Your local agricultural university or even your county extension agent should be able to help you determine the depth where ground temperature is constant in your area. Plan on burying pipes two feet or more below that level.