Separating variables we get
\begin{equation}
X'' +\lambda X=0,\qquad X(-1)=X(1)=0
\label{K}
\end{equation}
and
\begin{equation}
Y'' -\lambda Y=0.
\label{L}
\end{equation}
Solutions to (\ref{K}) we know:
\begin{equation}
\lambda_n= \left(\frac{\pi n}{2}\right)^2,\qquad X_n(x)= \sin \left(\frac{\pi n(x+1)}{2}\right)\qquad n=1,2,\ldots
\label{M}
\end{equation}
where $x+1 \in (0,2)$.
Then $Y_n (y) = A_n \exp \left(\frac{\pi n y}{2}\right) + B_n \exp \left(-\frac{\pi n y}{2}\right)$ but we take $A_n=0$ as this term grows as $y>0$. So
\begin{equation}
Y_n (y) = B_n \exp \left(-\frac{\pi n y}{2}\right).
\label{N}
\end{equation}
Or we can write (\ref{M}) as
\begin{gather}
\lambda_{2m+1}= \left(\frac{\pi (2m+1)}{2}\right)^2,\qquad X_{2m+1}(x)= \cos \left(\frac{\pi (2m+1)x}{2}\right),
\qquad m=0,1,2,\ldots \label{P}\\[3pt]
\lambda_{2m}= (\pi m )^2,\qquad X_{2m+1}= \cos (\pi m x)
\qquad m=0,1,2,\ldots \label{Q}
\end{gather}
(where we changed signs at these functions). So
\begin{align}
u(x,y) = &\sum_{m=0}^\infty B_{2m+1} \cos \left(\frac{\pi (2m+1)x}{2}\right) \exp \left(-\frac{\pi (2m+1) y}{2}\right)+\notag \\
&\sum_{m=1}^\infty B_{2m} \sin (\pi m x) \exp (-\pi m y).\label{R}
\end{align}
As $y=0$ we get
\begin{equation*}
1-|x| = \sum_{m=0}^\infty B_{2m+1} \cos \left(\frac{\pi (2m+1)x}{2}\right) +\sum_{m=1}^\infty B_{2m} \sin (\pi m x)
\end{equation*}
and since the left-hand expression is even we conclude that $A_{2m}=0$ and
\begin{multline*}
B_{2m+1}= 2\int_0^1 (1-x) \cos \left(\frac{\pi (2m+1)x}{2}\right)\,dx=\\
\frac{2}{(2m+1)\pi} (1-|x|)\sin \left(\frac{\pi (2m+1)x}{2}\right)\biggr|_{x=0}^{x=1} -
\frac{4}{(2m+1)^2\pi^2}\cos \left(\frac{\pi (2m+1)x}{2}\right)\biggr|_{x=0}^{x=1}=
-\frac{4}{(2m+1)^2\pi^2}.
\end{multline*}
Therefore
\begin{equation}
u(x,y) = \sum_{m=0}^\infty \frac{4}{(2m+1)^2\pi^2} \cos \left(\frac{\pi (2m+1)x}{2}\right) \exp \left(-\frac{\pi (2m+1) y}{2}\right) .
\end{equation}