Theorem:

I've a question regarding the proof of a theorem.

There is a theorem in my linear algebra book that states:

"If $\displaystyle A$ and $\displaystyle B$ are similar $\displaystyle n$ x $\displaystyle n$ matrices, then they have the same eigenvalues."

Proof of this theorem:

Let $\displaystyle A$ and $\displaystyle B$ be similar matrices so there exist an invertible matrix $\displaystyle P$ such that $\displaystyle B = P^{-1} A P$

By the properties of determinant it follows that:

$\displaystyle \begin{align*} \lvert{\lambda I - B}\rvert = \lvert \lambda I - P^{-1} A P \rvert =& \lvert P^{-1} \lambda I P - P^{-1} A P \rvert \\ =& \lvert P^{-1} (\lambda I - A) P \rvert \\ =& \lvert P^{-1} \rvert \lvert \lambda I - A \rvert \lvert P \rvert \\ =& \lvert P^{-1} \rvert \lvert P \rvert \lvert \lambda I - A \rvert \\ =& \lvert P^{-1} P \rvert \lvert \lambda I - A \rvert \\ =& \lvert \lambda I - A \rvert \end{align*}$

My question:

My question is: why is that

$\displaystyle \lambda I = P^{-1} \lambda I P $

How do you proof that left hand side of this statement is equal to the right hand side?

What property of linear algebra makes this true? I can't figure out the answer for this problem. Is it possible help me finding the answer?