I am having trouble understanding division in modular arithmetic. I didn't manage to find any good resources online on that.
Usually it is explained like this:
If we have $a \equiv b$ (mod $n$) with $a = ka'$ and $b = kb'$. Then by definition we have $k(a' - b') = qn$ for some integer $q$. Then they say that from this last equation we are sure that $n$ divides $(a' - b')$, but not $k$. Why is that?
Also it is said that one should divide $n$ with the $GCD(n,k)$, but I can not see how that comes into play.
Can anyone show modular division more generally or provide a good resource to study it?