There's usually two three-person crews on the station at any given time, so two capsules are kept docked and ready to serve as lifeboats.
Since the Soyuz is the sole means of transportation to and from the station, they simply put the capsules into a rotation. When a new crew arrives, they leave their capsule docked and the departing crew rides the oldest capsule back to Earth.
Since the Soyuz is the sole means of transportation to and from the station, they simply put the capsules into a rotation. When a new crew arrives, they leave their capsule docked and the departing crew rides the oldest capsule back to Earth.