A Schnorr group is a large prime-order subgroup of $\Bbb Z^*_p$, the multiplicative group of integers modulo $p$.
To generate such a group, we find $p = qr + 1$ such that $p$ and $q$ are prime.
Then, we choose any $h$ in the range $1 < h < p$ such that $h^r \not\equiv 1 \pmod p$.
The value $g=h^r \pmod p$ is a generator of a subgroup $\Bbb Z^*_p$ of order $q$.
Question: Where does $h^r \not\equiv 1 \pmod p$ condition come from? Why does the generator need to fulfill it?
I guess this is because, by lil' Fermat, we have $g^{q}\equiv h^{rq}=h^{p-1}\equiv 1\mod p$, so the order of $g$ is a divisor of $q$. As $q$ is prime, its order must be $1$ or $q$. Thus the condition ensures the order of $f$ is indeed $q$, not $1$.