Is it possible to subtract a matrix from both side? I have this equation $AX + B = I$ and I want to find Matrix $X$.
$$(A^{-1})AX + B = (A^{-1})I$$
$$X + B = (A^{-1})I$$
My question is, is it legal to do $X + B - B = (A^{-1})I - B$?
 A: Yes, this is legal, because there exists a (unique) matrix $C$ such that $B+C=C+B=0$ (where $0$ is the zero matrix). Precisely, the matrix $C$ has $(i,j)$-th entry $-b_{ij}$, where $b_{ij}$ is the $(i,j)$-th entry of $B$; we usually write $C=-B$. (It is also crucial that $0$ has the property $A+0=0+A=A$ for all matrices $A$, i.e. $0$ is an additive identity).
This property is "existence of additive inverses"; real (or complex) numbers also have this property, which is why this operation is legal in the setting you're more used to.
A: If two matrices are equal, then their differences with $B$ must be equal. How could it be that when you subtract $B$ from the same matrix (equal matrices have equal entries) you get two different answers?
That said, if two matrices are equal, then their products with $A^{-1}$ on the left are equal, too, assuming the inverse and products are defined. But they may not be: not every matrix is invertible, and not every matrix product is defined, because of they might have the wrong dimensions. 
However, as Riccardo.Alestra pointed out, your equal matrices are $AX+B$ and $I$, so when you multiply them by $A^{-1}$ on the left, you should have $A^{-1}\left(AX+B\right)=A^{-1}I$ which simplifies differently than what you wrote in your question.
A: $AX+B=I$, $A^{-1}AX+A^{-1}B=A^{-1}I$. So: 
$X=A^{-1}I-A^{-1}B$. It's legal.
