Angular momentum superposition

I am doing a space simulation. I have a spaceship and this spaceship has engines that don't push the spaceship through its center of gravity. These engines can therefore give the spaceship angular momentum.

However, I have no idea how to compute the superposition of rotations around multiple axes. Any ideas ?.

Since rotation is preserved, the engines could apply angular momentum around any angle, depending on the spaceship's orientation.

I would like to be able to just rotate the spaceship around two perpendicular axes.

I might be mistaken, but I think I can achieve all possible rotations using the X and Y euclidean axes, for example. Is this right ?.

If so, how can I translate arbitrary rotations to rotations around these two axes ?. One thing I have thought of is to do all the rotations on three perpendicular unit vectors, and then measure the resulting angles around X and Y. Is there a more straightforward way of doing this ?.

If care only about the direction the nose of the ship is pointing to, and you don't care about "roll" around final the axis of the ship, then you can achieve any direction orientation by a simple combination of a rotation about the ship's Y and Z axes (I use the standard aeronautics convention of saying the forward direction is toward $+X$).
To achieve elevation of $\theta$ and azimuth of $\phi$ you merely rotate by $\phi$ about the $Z$ axis followed by a rotation by $\theta$ about the new $Y$ axis.
To get a fully general rotation, the simplest additional step is to now rotate about the new $X$ axis so that the roll is the desired roll. (The angles used are called the Tait-Bryan angle representation of the rotation.)
However, you can achieve any arbitrary rotation by rotating about the $Z$ axis, then the new $Y$ axis, and finally by some different amount about the new $Z$ axis -- only two axes used. This is the "(proper) Euler Angles" description of the rotation. If you do care about the ending roll as well as the direction of the nose, it is not a simple matter to determine the needed individual Euler angles.