Number theory!Polynomial modules From Fermats theorem we know that for every $a \in \mathbb{Z}$, $$a^p\equiv a \mod{p}$$. But the polynomial $x^p$ it is not equal to the polynomial $x$( as a Congruence ). Why?Also when you want to solve a polynomial equation with modules you use that fermats theorem to simplify the polynomial.Doesnt that contradicts that  $x^p$ is not equal to $x$. SInce for every $a \in \mathbb{Z}$ $$a^p\equiv a \mod{p}$$
 A: You have to make a distinction between (more concrete) functions from $\Bbb Z / p \Bbb Z$ to $\Bbb Z/p \Bbb Z$ and (more abstract) polynomials with coefficients in $\Bbb Z/ p \Bbb Z$. 
For each polynomial, there is an associated polynomial function. And as you have just discovered, it is NOT true that if the polynomial function is zero, then the polynomial is also zero.
On any finite ring $R$, you can make the polynomial $\prod_{x \in R} (X - x)$, whose polynomial function is obviously zero. But this polynomial is not zero !
A: Over the reals (or any infinite field), a polynomial induces the zero function iff it is the zero polynomial because a polynomial cannot have an infinite number of roots.
Things are different in finite fields. If the field has $q$ elements, then $X^{q}-X$ induces the zero function but is not the zero polynomial.
A: The polynomial $x^2+x$ is always divisible by 2, but as polynomials $x^2+x\not\equiv0\pmod2$ -- for one thing, the degree on the left is different from the degree on the right.
Similarly, even though $x^p-x$ is zero mod $p$ for any $x$, as polynomials, $x^p$ and $x$ are different.
Basically "are equivalent as polynomials" is a fine-grained tool where "are equal at all integer $x$" is courser. If you know that $P(x)$ and $Q(x)$ are equivalent (mod $p$) as polynomials then you know that they take on the same value (mod $p$) for all integer $x$, but you can't conclude the converse.
A: Do you know the difference between Congruence Equation and Algebraic equation which obeys Fundamental theorem of algebra unlike the previous one?
For example $$x^2\equiv2\pmod3$$ is not solvable unlike $$x^2=2$$ 
Again, $$a^p\equiv a\pmod p$$ is basically Identity Congruence Equation i.e., any integer satisfies this equation   just like $$\prod_{r=0}^{p-1}(x-r)\equiv0\pmod p$$
