Seasons result from Earth's axial tilt of approximately 23.5° relative to its orbital plane around the Sun (the ecliptic). Not from distance—Earth is actually closest to the Sun (perihelion) in January.
Axial precession—a 26,000-year wobble of Earth's axis (like a spinning top)—gradually shifts the timing of seasons relative to Earth's orbit (e.g., which hemisphere gets summer at perihelion). This affects long-term climate (Milankovitch cycles) but does not change the fundamental mechanism: tilt + orbit = seasons.
In short: the hemisphere tilted toward the Sun gets summer; the one tilted away gets winter. The tilt is constant; the orientation relative to the Sun changes as Earth orbits.