Harmonic and isometric rotations around a submanifold