If there are six onboard two Soyuz will be docked. Always. There will never not be lifeboat for everyone, nor was there ever not one for everyone. Currently two are docked and those are the two lifeboats.
Those aren’t only lifeboats, though. They are also just the normal crew return vehicles. Here is how crew rotation currently works: Three depart in the oldest Soyuz docked to the station, leaving the station with a crew of three and only one remaining Soyuz. A couple days later a new Soyuz arrives at the station, meaning there’s now a crew of six and two Soyuz docked to the station. Then everyone stays up there for a couple months longer before the now veteran crew departs on the oldest Soyuz and everything repeats.
One advantage of doing it this way is that you are constantly renewing the lifeboats, so a Soyuz doesn’t have to survive years in space, only six or so months before it is replaced. Basically, it has to work for its main purpose (returning the crew to Earth as planned) anyway, insuring that it also works as a lifeboat. (Though I would assume that many changes were made to make the Soyuz work as a lifeboat. I would imagine that rapidly departing from the station, potentially with injured crew, is quite a different task compared to a planned departure.)
This makes me wonder, I assume they have procedures to dock a deserted ISS, right? What would happen in case of an emergency where both teams (3+3) have to return back to Earth, leaving ISS without a crew? Will they be able to "get back in"?
Continuous habitation of a space station is a bit historically unusual. Skylab had three visiting manned missions, none of which overlapped. Early Russian stations operated similarly. Mir was operated more like ISS, but left unoccupied several times. (See http://en.wikipedia.org/wiki/Soyuz_TM-30 for a commercial mission to revive and try to restore the previously-abandoned MIR.)
And the ISS (or early parts thereof) went about two years before its first long-term crew.
So, yes, you can get back into the ISS if it's empty. That capability has been designed into both halves of the space station from the beginning.
Soyuz can dock to deserted stations, or at least could in the past. They had to do it all the time with the Salyut stations, and I suspect it is how the first docking with the ISS went down as well.
Technically there is berthing and there is docking. Berthing requires that both sides cooperate, but docking doesn't necessarily require this. However while docking both sides are very nearly always under control (with the deserted side under robotic control).
Non-cooperative docking has only been done exactly once in the history of human spaceflight on the Soyuz T-13 mission to the Salyut 7 space station [0]. In addition, Wikipedia mentions a few unmanned tests.
In practice, all spacecraft docking and berthing operations are fully automated and no human intervention is required apart from emergency conditions (which have never occured). The last intentional attempt (1997) at manual docking ended up in a bad collision between the Mir space station and a Progress spacecraft [1]. The last Mir mission (Soyuz TM-30) did the last few meters under manual control. ISS crews are trained for manual docking but I don't think has ever been necessary.
In the hypothetical situation that the ISS would be left unmanned, it's extremely unlikely that they would decide to (or have time to) power down the attitude control systems (control moment gyroscopes and thrusters). So even if the station ended up unmanned, it's not likely that it would be non-cooperative (ie. out of control). If all the attitude control systems would disabled because of damage (e.g. fire), the station would probably not be salvageable.
So it's possible but very unlikely to have a scenario where a manned mission would need to manually dock an out of control space station. But it has happened once before, so it's not impossible either.
Well, the ISS was actually built as a constant iterative process, it wasn't just sent on space as is and then assumed operative. Also I'd assume the first module that was sent to space might have contained humans already right on departure from the Earth.
But yeah, obviously they have procedures to retrieve and re-enter an empty ISS, I was mostly curious how or if there's any material around.
Zarya (the first module, launched in 1998) was pressurized and could support a crew short-term-- the crew of STS-88 (which launched Unity, the second module added to the ISS) entered the station and began unstowing gear and stuff. The ISS couldn't support its permanent crew until Zvezda (the station's service module) launched in 2000, though-- Zvezda contains the station's primary life support equipment and contained crew facilities like toilets and bunks.
My guess of a likely reason to completely evac the station is one astronaut gets hurt, two healthy astronauts land with the sick one, then in a stroke of incredibly bad luck another astronaut gets hurt. For hurt, substitute in appendicitis, broken arm, heart attack, severe burn, poisoning from some kind of leak (ammonia?). If you're looking for a hard sci fi plot line, maybe major system malfunction hurts one astronaut, then after the medivac, while making duct tape repairs, another gets hurt, then the space pirates arrive and take charge of a derelict abandoned vessel, or whatever.
I would guess that docking with a completely dead powered down archeological relic of a station would be much more exciting than docking with a powered up and running station that merely happens to not have any humans onboard.
Station without power would start to tumble. Makes docking much harder. This actually happened with Salyut 7: the station died on orbit, no electrical or anything. The pilot of the rescue Soyuz matched its spin to dock manually. Effected emergency repairs while wearing fur-lined winter clothing.
It must not have been tumbling too badly. Seems like once you have significant motion in more than one axis it'd be pretty hard to match up. At that point, you probably have to grab and despin, or something. Or dock really really fast and hope your docking mechanism holds up to the stress.
Trying to fix/salvage it? I'm sure the russians reactivated a "dead" station at least once, sending a better prepared crew to repair quite a while after it was abandoned.