The role of spin-lattice coupling for ultrafast changes of the magnetic order in rare earth metals