I have two groups defined by presentations $$\langle x, y \mid x^p = y^q \rangle$$ $$\langle x, y \mid x^{p'} = y^{q'} \rangle$$ where $p,q,p',q'$ are all integers greater then $1$, and $\gcd(p,q) = 1$, $\gcd(p',q')=1$.
I'm not 100% sure, but i think they are not isomorphic. But I don't know how to prove it. Any ideas?
Let $G = G_{pq} = \langle x,y \mid x^p=y^q \rangle$, with $p \le q$. Then $Z := Z(G)$ is the infinite cyclic group generated by $x^p$, and $G/Z$ is the free product of cyclic groups of orders $p$ and $q$, so its abelianization is $C_p \times C_q$.
One of the standard properties of free products $A*B$ is that any element of finite order is contained in a conjugate of $A$ or $B$. So the maximum finite order of an element of $G/Z$ is $q$.
Now if $G_{pq} \cong G_{p'q'}$ with $p \le q$ and $p' \le q'$, then $pq = p'q'$ from the abelianizations of $G/Z$, and $q=q'$ from maximum finite orders of elements in $G/Z$, and hence $p=p'$.
You don't need the comprimeness asumption.