Groundwater flow plays an important role in the operational efficiency of geothermal systems. Although numerous studies have investigated the heat transfer mechanism near to geothermal boreholes in the presence of groundwater flow, the majority of them have primarily focused on fully saturated soil condition. Only a limited number of studies have explored the heat transfer mechanism in layered ground with subsurface flow. Furthermore, almost all of these studies have disregarded the phase change occurrence and the movement of liquid and vapor water within the unsaturated layer. However, recent research has demonstrated the considerable influence that these parameters can have on the heat transfer mechanism. Therefore, in the current study, a fully thermo-hydraulic model was developed in COMSOL Multiphysics to assess the effect of hydraulic equations in heat transfer close to a partially submerged heat source in the groundwater flow. The soil thermal response was compared with and without considering hydraulic formulation (i.e., phase change, liquid and vapor flow in unsaturated soil, and thermally induced fluid flow in saturated soil), while two different soil permeabilities were considered for the soil. The results showed a considerable change in the soil temperature when the hydraulic equations were taken into account; however, the influence of hydraulic equations on temperature was different in different permeabilities.