You see, there are other seemingly unlikely identities... $${\left(\sqrt{2}^{\sqrt2}\right)}^{\sqrt{2}} = 2,$$ $$\log 2 + \log 5 = 1,$$ etc.
The fact is, $\pi$ is defined such that the identity holds. Usually $\pi$ is defined as the smallest positive number such that $2\pi$ is a period of $f(x)=e^{ix}$. So $e^{i\pi}$ must be a square root of $1$, but since $2\pi$ is the smallest positive period, you can't take to positive square root. Therefore $e^{i\pi}=-1$.
To see why this is a good definition, consider doing this the other way: defining $\pi$ with circumference requires a definition of curve length, which requires the definition of improper integrals, the smallest positive period approach only requires the definition of $e^x$ as a power series sum, which only requires the definition of limits. You can also define $e^x$ as a unique solution to a differential equation, which is also straightforward. This is the definition used in Rudin's real analysis book.