Let's begin by presenting a simple example of representing a function with a series. Let $f(z)=\frac{1}{1-z}$ for $z\ne 1$. Recall that $f(z)$ can be represented by the geometric series
$$f(z)=\sum_{n=0}^\infty z^n \tag 1$$
for $|z|<1$. So, although $f(z)$ exists for all $z\ne 1$, its representation as given in $(1)$ is valid only when $|z|<1$.
We can also represent $f(z)$ by the series
$$f(z)=-\sum_{n=1}^\infty \left(\frac{1}{z}\right)^n \tag 2$$
for $|z|>1$. So, we have two representations for the same function that are valid in distinct regions of the complex $z$-plane.
Now, suppose that we represent the function denoted $\zeta(s)$ by the series
$$\zeta(s)=\sum_{n=1}^\infty \frac{1}{n^s}$$
for $\text{Re}(s)>1$. We can easily extend the definition by writing
$$\underbrace{\sum_{n=1}^{\infty}\frac{1}{n^s}}_{\zeta(s)}=\underbrace{2\sum_{n=1}^{\infty}\frac{1}{(2n)^s}}_{2^{1-s}\zeta(s)} -\sum_{n=1}^{\infty} \frac{(-1)^n}{n^s}\tag 3$$
for $\text{Re}(s)>1$. Upon rearranging $(3)$ we find
$$\zeta(s)=(1-2^{1-s})^{-1}\sum_{n=1}^\infty\frac{(-1)^{n-1}}{n^s}\tag 4$$
But notice that the series on the right-hand side of $(4)$ converges for $\text{Re}(s)>0$. So, we have just developed another representation for $\zeta(s)$ that is valid in a larger region of the complex $s$-plane.
There are other series representations of the Riemann Zeta function, such as its Laurent series,
$$\zeta(s)=\frac1{s-1}+\sum_{n=1}^\infty \frac{(-1)^n\gamma_n}{n!}(s-1)^n$$
which converges for all $s\ne 1$.
And there are integral representation of $\zeta(s)$ such as
$$\zeta(s)=\frac1{\Gamma(s)}\int_0^\infty \frac{x^{s-1}}{e^x-1}\,dx$$
which converges for $\text{Re}(s)>1$ and (see 25.5.11 this reference)
$$\zeta(s)=\frac12 +\frac{1}{s-1}-2 \int_0^\infty \frac{\sin(s\arctan(x))}{(1+x^2)^{s/2}(e^{2\pi x}+1)}\,dx$$
which is valid for all $s\ne 1$.
Since the equality$$\Gamma(s)\zeta(s)=\int_0^\infty\frac{x^{s-1}}{e^x-1}\,\mathrm ds$$holds when $s\in(1,\infty)$, and since $s\mapsto\Gamma(s)\zeta(s)$ and $s\mapsto\int_0^\infty\frac{x^{s-1}}{e^x-1}\,\mathrm ds$ are analytic functions defined on $\{z\in\mathbb C\mid\operatorname{Re}z>1\}$, then we have$$\operatorname{Re}z>1\implies\Gamma(s)\zeta(s)=\int_0^\infty\frac{x^{s-1}}{e^x-1}\,\mathrm ds$$by the identity theorem.
Best Answer
I'll give you the world's simplest example. $1+x+x^2+\dots$ converges for $|x|\lt1$ only. The function $1/(1-x)$ is analytic everywhere except for a pole at $x=1$, and agrees with $1+x+x^2+\dots$ everywhere the latter is defined, so $1/(1-x)$ is the analytic continuation of $1+x+x^2+\dots$. In that sense, $1+2+4+\dots=-1$.