My theory on the end...SPOILERS
They never left the many extended universes created by the room. Shane originally created an extended universe within the room. While in the room running from the faux house through the forest to the real house, Matt was probably wishing he could get back in time to save Kate. The room creates another fake universe, possibly with fake Kates and Shanes to make this wish come true.
As they were all running around in the house, it's possible the room created layers and layers of universes in an effort to satisfy the wishes of both sides. At one point we see the house being distorted like an Escher painting and it's implied there are multiple versions of Kate and Matt running around.
When all is finally over, Kate and Matt assume they are back in the real world and carry on. At the end when Kate's wish to get pregnant comes true and the lights flicker, her look of fear reflects her realization that they are still in the room with no way to get out.