Consider zeros of $f$. If $f(0)=0$, we can, for some n, write $f(z)=z^n g(z)$, $f(qz)=z^n q^n g(qz)$, and we find that $g(z)/g(qz)$ is also a linear function. Now let us say $g(z)/g(qz)=az+b$. By plugging in $z=0$, we find $b=1$. Moreover, $g(-1/a)=0$. Since $az+1$ has no poles, we recursively find $g(-1/(qa))=g(-1/(q^2a))=...=0$. Now let $h(z)=\prod_{n=0}^\infty (aq^nz+1)$. Since $|q|<1$, this is a convergent product. Define $u(z)=g(z)/h(z)$. We find that $u(z)/u(qz)=1$. This yields
$u(1)=u(1/q)=u(1/q^2)$=...=$u(0)$, which implies that u is constant.