This question has already answered here in other topics, but all answers that I read have some techniques like congruence and fermat numbers and the book which I am reading shows this question in chapter about divisibility. So I have been looking for a way of resolving this problem just using divisibility.
I found a document that brings an answer considering just divisibility, but there are two parts of the solution that I haven't already understood yet. I have read it many times but no success. Here they are
1) why can't $x$ and $y$ be both positive?
2) why did he consider the power $a^{-ny}$, instead of $a^{ny}$, since it is well-known that $t$ divides $a^{ny}-1$?
See remarks on the attached picture in
Regarding your first part, $x,y$ cannot be both positive. If so, then $d\geq m+n$. But this is impossible, since $d|a \implies d \leq a$. Do not forget that $m,n$ are both positive by the hypothesis.
Regarding your second part, we have assumed, by the first part, Without Loss of Generality, that $y$ is negative. Now, the term $(a^{ny}-1)$ is not an integer since $a^{ny}$ is a fraction. Hence, we need to negate it to make the power positive. i.e. $(a^{-ny}-1)$.
I hope now it is clear.