The alternator is responsible for charging the car battery and powering all the car's onboard network consumers. If it fails or is unstable, the battery will either not be charged or start discharging ...
Your car only starts reliably because two electrical workhorses share the load. The battery delivers instant power on demand, while the alternator keeps that energy flowing once the engine runs.