Conveniently, according to the theory of relativity any frame of reference is acceptable. Pick whichever you like.
Define frame in the absence of matter/energy.
So they had to make the necessary adjustments by firing their gimbaled rockets at the right time and direction. But they had no way to do it without a frame of reference. Then the Tom Hanks character, Jim Lovell, decided he would use the earth in the window as his point of reference.
Outstanding movie BTW.
,,Houston....I think we've got a problem