I think your book's explanation is a bit unintuitive. Really the key is to spot that this matrix
\begin{equation*}
\begin{pmatrix} 2 & -2 \\ 2 & 2 \end{pmatrix}
\end{equation*}
looks a lot like a rotation already! Particularly, the diagonal elements are the same, and the off-diagonal elements differ by multiplication by $-1$. This is the form of a general scaling-rotation combination. In fact, if we multiply the general rotation and scaling matrices together, we get
\begin{equation*}
\begin{pmatrix} \alpha \sin \theta & -\alpha \cos \theta \\
\alpha \cos \theta & \alpha \sin \theta \end{pmatrix}
\end{equation*}
which I'll leave as an exercise for you. Note that it doesn't matter if you multiply by the rotation on the left or the right, or in fact if you multiply by more rotations or scalings, the general form doesn't change! If you think about it geometrically, this makes sense. Rotating multiple times is the same as rotating once by the total angle of rotation, and scaling multiple times is the same as scaling once by the compound scale factor. Moreover, it doesn't matter if you scale first and then rotate, or rotate and then scale.
Anyway, we now want to find $\alpha$ and $\theta$ such that $\alpha \sin \theta = 2$, and $\alpha \cos \theta = 2$. (It should be clear that if we accomplish this, then the general matrix becomes the matrix we're looking for).
Now, looking at this, we can eliminate the trig functions by taking the sum of squares:
\begin{equation*}
(\alpha \sin \theta)^2 + (\alpha \cos \theta)^2 = \alpha^2 = 2^2 + 2^2
\end{equation*}
ie $\alpha^2 = 8$. So let's take $\alpha = \sqrt 8 = 2 \sqrt 2$.
Then, substituting back in, it just remains to find $\theta$ such that
$\sin \theta = \cos \theta = \tfrac 12 \sqrt 2$. The special angle $\pi/4$ is fairly well-known to have this property. If you didn't know that, you could combine them to get $\tan \theta = 1$ and solve that, but you have to watch out that the solution to this is actually consistent with the two previous equations.
A way to think about why it works to square and add the equations is that the point $(\alpha \sin \theta, \alpha \cos \theta)$ lies on the circle centred at the origin with radius $\alpha$, so finding the distance from the origin tells us $\alpha$. This has a lot to do with your book's approach. Note that we could also have taken $\alpha = -2\sqrt 2$. Can you find what the corresponding $\theta$ would be?
Not all matrices can be written as such a product. Particularly, note that if two vectors are perpendicular to each other, then scaling and rotating them keeps them perpendicular. But for example, the matrix
\begin{equation*}
\begin{pmatrix}
1 & 0 \\
0 & 0
\end{pmatrix}
\end{equation*}
sends both of the perpendicular vectors $(1, 1)$ and $(1, -1)$ to $(1, 0)$. Another way to look at it is that not every matrix has the same general form I mentioned earlier.