I'm assuming your function has domain all of $\mathbb{R}^2$. For the codomain, some subset of $\mathbb{R}$. But you should state them explicitly, especially when you are trying to figure out if the function is one-to-one and/or onto; those properties depend on the domain the codomain, not just on the formula.
To show the function is onto, given any $z$ you just need to produce a single pair $(x,y)$ that maps to $z$.
Your "argument" does not really work. You are defining $x$ in terms of both $z$ and $y$, and then defining $y$ in terms of both $z$ and $x$; you have a circular definition.
For instance, say I ask you to use your formula to produce a pair $(x,y)$ that maps to $z=1$. You say: "take $x = (z-y)/2 = (1-y)/2$, and then $y=z-2x = 1-2x$. So $x=(1-y)/2$, and $y=1-2x$."
Ehr... okay. But what are $x$ and $y$? If you plug in the value of $x$ into the formula for $y$, you get $y=y$; if you plug in the value of $y$ into the formula for $x$, you get $x=x$. You aren't giving any pair that maps to $1$.
So, instead, given $z$, produce a specific value of $x$ and of $y$ (that depends on $z$, of course, but not on $x$ or $y$) that will map to $z$.
For one-to-one, your reasoning breaks down. Once you get to $2(x_1-x_2) = (y_2-y_1)$, you have no warrant for the assertion that $y_1=y_2$ and $x_1=x_2$. If one of them holds, then the other holds; but what if neither holds? For instance, if $x_1=2$ and $x_2=1$, can you find $y_1$ and $y_2$ that will make the equality true anyway? If so, then you can simply exhibit the pairs $(2,y_1)$ and $(1,y_2)$ to show that the function is not one-to-one, since you can find two distinct pairs that map to the same thing.