The water table is not flat. The water table is higher under hills than under valleys. Groundwater flow is impeded by indirect flow around grains. Permeable layers are called aquifers. Impermeable layers are called aquicludes.
Springs arise from a perched water table.
Otherwise groundwater discharges into streams as a consequence of flowing from a higher water under hills towards the lower water table in valleys. If water discharges into a stream, the water table comes to surface right at the stream. In this case the water table slopes downhill toward the stream. Wells are drilled into the zone of saturation below the water table. Groundwater is an exhaustible resource.