Here is a brief analysis of the problem which involves:
i) Momentum and the concept of impulse
ii) Analysis of a force into two components
iii) Moment of a force
iv) Moment of inertia and the parallel axis theorem
For the sake of simplicity let us assume we have a spherical spaceship of radius R in the outer space. Let there be a rocket at the surface of the spaceship pointing in a direction that does not pass through the centre of the sphere. Imagine now we are firing the rocket.
The impulse will generate a force, $F$, in the usual way and push the spaceship in the direction of the rocket. The force exerted on the sphere in that direction can be analysed into the tangent and the perpendicular to the surface of the sphere. If $\theta$ is the angle between the rocket direction and the normal to the sphere we have:
Tangent component: $F_T=F\sin(\theta)$
Normal component: $F_N=F\cos(\theta)$.
The normal component is parallel to the radius of the sphere and passes through the centre (CM) and has no moment with respect to the centre. This component will push the sphere in the normal direction.
The tangent component has a moment with respect to the centre
$M=FR\sin(\theta)$.
This component would rotate the sphere, should the axis of the sphere be pivoted, but it is not! However, due to the inertia of the mass of the sphere, it would be sufficient to give a pivotal leverage for the tangent force to rotate the sphere. The law of conservation of energy must be written, for a short time interval of application of the force, as it moves the spaceship by a displacement ${\bf x}$, in the form
${\bf F.x}=\frac {1}{2}mv^2+ {\frac {1}{2}I{\omega}^2}$
The first term on the RHS is the kinetic energy due to the linear motion, and the second is the kinetic energy due to the rotational motion.
The spaceship will rotate about the centre of mass of the spaceship, and the axis of rotation will be perpendicular to the plane made between the tangent force and the radius of the sphere. The axis will pass through the centre of the sphere because, according the parallel axis theorem, the moment of inertial is minimum when the axis of rotation passes through the centre of mass. Hence the spaceship will have the minimum energy, and this is the preferred energy state for the spaceship.