Let $H$ be a Sylow $p$-subgroup of $G$ and let $K$ be a Sylow $q$-subgroup of $G$. Sylow’s Third Theorem states that the number of Sylow $p$-subgroups of $G$ is of the form $1+kp$ and divides $pq$. So $1+kp$ is equal to $1, p, q,$ or $pq$. From this and the fact that $p$ does not divide $q-1$, it follows that $k=0$, and therefore H is the only Sylow p-subgroup of G.
This is part of the proof of the theorem.
What I don't understand is the bolded part of the proof. How does this imply that $k=0$?
I can see that because $p$ does not divide $q-1$ implies that $1+kp \neq q$, but beyond this I'm confused.
If $k\ne 0$, then $\text{gcd}(1+kp,p)=1$, so that we must have $1+kp$ dividing $q$.