Conservative mass transfer in close binary systems. I. Equations of motion for spin and orbital angular momenta.