Solve this by analogy with a translating body (not rotating). Its linear momentum $p$ is:
$$p=mv$$
With $m$ the mass and $v$ the linear velocity.
Take the derivative to time of both sides:
$$\frac{dp}{dt}=m\frac{dv}{dt}=ma=F$$
For a purely rotating body the angular momentum is $\vec{L}$:
$$\vec{L}=I\vec{\omega}$$
Where $\vec{\omega}$ is the angular velocity and $I$ the moment of inertia about the axis of rotation.
Take the derivative in time of both sides:
$$\frac{d\vec{L}}{dt}=I\frac{d\vec{\omega}}{dt}=\vec{\tau}$$ Where $\vec{\tau}$ is the torque vector required to effectuate a change in direction of the angular momentum vector $\vec{\omega}$.
In scalar notation we can write:
$$\tau=\alpha I$$
Where $\alpha$ is the rate of change of direction of the $\vec{\omega}$ vector in $\mathrm{radians/s}$. If you want the flywheel to change its plane of rotation only slowly then only a small torque is needed but faster changes require higher torque.