(a) You were doing fine until you got to transitivity. There your assumption is that $(z_1,n_1)\sim(z_2,n_2)$ and $(z_2,n_2)\sim(z_3,n_3)$, and you want to prove that $(z_1,n_1)\sim(z_3,n_3)$. Begin by translating these into the language of the specific relation $\sim$. You know that $z_1 \cdot n_2 = z_2 \cdot n_1\tag{1}$ and that $z_2 \cdot n_3=z_3 \cdot n_2,\tag{2}$ and you want to show that $z_1 \cdot n_3=z_3 \cdot n_1.\tag{3}$
Notice that in your version you got both $(2)$ and $(3)$ wrong: you didn’t correctly translate $(z_2,n_2)\sim(z_3,n_3)$ and $(z_1,n_1)\sim(z_3,n_3)$.
Now, how can you use $(1)$ and $(2)$ to get $(3)$? In you could get something involving $z_1 \cdot n_3$ on the lefthand side by multiplying $(1)$ and $(2)$ together: $z_1 \cdot n_2 \cdot z_2 \cdot n_3=z_2 \cdot n_1 \cdot z_3 \cdot n_2.\tag{4}$ Let’s isolate the parts of interest on each side of $(4)$: $(z_1 \cdot n_3) \cdot (n_2\cdot z_2)=(z_3 \cdot n_1) \cdot (n_2 \cdot z_2)\;.\tag{5}$ Look at the unwanted parts: they’re the same on both sides. It would be nice to cancel them, but be careful: they could be $0$, in which case cancellation wouldn’t be possible. You’ll have to deal with that possibility as a separate, special case. If $n_2 \cdot z_2=0$, why is $(3)$ still true?
(b) You’ve almost hit on the right idea in your own post. If $(z_1,n_1)\sim(z_2,n_2)$, what can you say about the rational numbers $\dfrac{z_1}{n_1}$ and $\dfrac{z_2}{n_2}$? (I’m assuming that for you $\mathbb{N}$ does not include $0$; be aware that for many of us it does, so you should always specify which version you mean.)
Added: You want a bijection from $f:M\to\mathbb{Q}$, where $M=\left\{\widetilde{(z,n)}:(z,n)\in\mathbb{Z}\times\mathbb{N}\right\}.$ Each $\widetilde{(z,n)}\in M$ has many names; for example, $\widetilde{(3,2)}=\widetilde{(6,4)}=\widetilde{(18,12)}\;.$ Similarly, each rational number has many names; for example, $\frac32=\frac64=\frac{18}{12}.$ What’s the rule for deciding whether $\widetilde{(z_1,n_1)}$ and $\widetilde{(z_2,n_2)}$ are two names for the same member of $M$? That’s the case if and only if $(z_1,n_1)\sim(z_2,n_2)$, so $\widetilde{(z_1,n_1)}=\widetilde{(z_2,n_2)}\iff z_1n_2=z_2n_1\;.\tag{6}$
Now what’s the rule for deciding whether $\frac{z_1}{n_1}$ and $\frac{z_2}{n_2}$ are different names for the same rational number? $\frac{z_1}{n_1}=\frac{z_2}{n_2}\iff z_1n_2=z_2n_1\;.\tag{7}$
Now $(6)$ and $(7)$ look an awful lot alike, so why not try the map $f:M\to\mathbb{Q}:\widetilde{(z,n)}\mapsto\frac{z}n\;?$ There’s still a fair bit of work to be done: you have to show that $f$ is well-defined, meaning that if $\widetilde{(z_1,n_1)}=\widetilde{(z_2,n_2)}$, then $f\big(\widetilde{(z_1,n_1)}\big)=f\big(\widetilde{(z_2,n_2)}\big)$, and you have to check that it really is a bijection.