I have to find the extremas of $f(x, y, z)=x+y+z$ subject to $x^2-y^2=1$, $2x+z=1$.
I have done the following:
We will use the theorem of Lagrange multipliers.
The constraints are $$g_1(x,y,z)=x^2-y^2-1=0 \ \ , \ \ g_2(x, y, z)=2x+z-1=0$$
We are looking for $x$, $y$, $z$, $\lambda_1$ and $\lambda_2$ such that $$\nabla f(x, y, z)=\lambda_1 \nabla g_1(x, y, z)+\lambda_2 \nabla g_2(x, y, z) \tag 1$$ and $$g_1 (x, y, z)=0 \tag 2$$ $$g_2(x, y, z)=0\tag 3$$
$$(1) \Rightarrow (1, 1, 1)=\lambda_1(2x, -2y, 0)+\lambda_2(2, 0, 1)$$
So, we have that $$1=2\lambda_1 x+2\lambda_2 \\ 1=-2\lambda_1 y \\ 1=\lambda_2$$
So, we get $x=y$, right??
When we apply this at the first constraint $g_1(x, y, z)=0$ we get $-1=0$, or not??
What have I done wrong??
You haven't actually done anything wrong: the function has no extreme values subject to these constraints. (Or at least, none that are not on the boundary.) This is easy to check in this case: first, you can see that $z=1-2x$, and substitute that in: $$ \text{Extremise } 1-x+y, \quad \text{with} \quad x^2-y^2=1. $$ (At this point, I am suspicious that $x-y$ appears in both the function and the condition, but I don't see how to use this directly...) One way to work now is pictorially: $x^2-y^2=1$ is a hyperbola, so you can draw that, and look at the lines $-x+y=k$ and their intersections with it.
Another, more explicit way is to set $$ 2x= t+t^{-1}, \quad 2y = -t+t^{-1}. $$ This parametrises the whole hyperbola, as I showed in this answer (well, with $t$ replaced by $1/t$, which is clearly equivalent), and hence you now automatically have $x^2-y^2=1$. Then $$ f(x,y,z) = 1-x+y = 1-\frac{1}{2}(t+1/t)+\frac{1}{2}(-t+1/t) = 1-t, $$ which obviously has no extrema (although note that we cannot have $t=0$, because $t=x+y$ and $(x+y)(x-y)=1$. Hence there are no extrema: the function approaches $\infty,1,-\infty$ as $t \to -\infty,0,\infty$ respectively.