Is $n$ only a number?
$n$ is indeed a number. Is it only a number? Well it's a quantum number which means it labels the $n^{\textrm{th}}$ excited energy level of the system (i.e. the $(n+1)^{\textrm{th}}$ smallest eigenvalue of the system's Hamiltonian, with $n=0$ corresponding to the smallest eigenvalue, $n=1$ corresponding to the second smallest eigenvalue, etc.
If so then how does $n = 0$ have anything to do with temperature?
The density matrix of a system with the harmonic oscillator potential is often given in terms of the Hamiltonian $H$ by:
\begin{equation}
\rho = \frac{e^{-\beta H}}{\textrm{tr}\left(e^{-\beta H}\right)},~~~~~~~~\beta\equiv \frac{1}{k_BT}.
\tag{1}
\label{eq:boltzmann}
\end{equation}
The diagonals of the density matrix from top-left to bottom-right then tell you the probability of finding the system in $n=0,1,2,\ldots$, meaning that if the top-left element of the density matrix is $p$, the system's probability of being found at the energy level corresponding to $n=0$ is $p$. When $T=0$ we have that the probability of the system being in any excited state ($n>0$) is extremely supressed by the decaying exponential, and you can count on finding the system at the $n=0$ level. When $T$ is larger, the excited states will more likely get populated. As $T$ approaches $+\infty$, the exponential becomes close to 1 and we approach a scenario where the probabilities become equal for each state $n$.
Eq. 1 in this answer is also: