The magnetic moment \( \mu \) of a current-carrying loop is given by the formula:
\[
\mu = I A
\]
where:
- \( I \) is the current,
- \( A \) is the area of the loop.
For a rectangular loop with side lengths \( a \) and \( a \), the area of the loop is:
\[
A = a^2
\]
Thus, the magnetic moment of the loop is:
\[
\mu = I \times a^2
\]
Therefore, the correct answer is \( I a^2 \).