Magnetic phase transition and relaxation effects in lithium iron phosphate