If you have an irreducible polynomial $f(x)$ over $GF(q)$, then the following should be true: $GF(q)/f(x) \cong GF(q^k)$, where $k = deg(f(x))$. So the multiplicative group should have $\varphi(q^k)$ elements, where $\varphi$ is the totient.
On the other hand, since $f(x)$ is irreducible, doesn't that mean that there are no divisors of $f(x)$ in $GF(q)/f(x)$, so all of its elements should be part of the multiplicative group, save for $0$. So, arguing that way, the group should have $q^k-1$ elements.
It seems to me that I have a misunderstanding of the problem at hand, but I cannot figure out where my misconception lies. Can anyone point out what I'm doing wrong?
$\varphi(q^k)$ is the cardinality of the multiplicative group of units of the ring $\mathbf Z/q^f\mathbf Z$, which has $q^k$ elements too, but is not even an integral domain (it's an artinian local ring, with maximal ideal $(p)/(q^k)$, if $q$ is a power of the prime $p$).