Why is Pauli exclusion principle necessary? Why is it not possible to put two fermions in the same quantum state? I read in some book that this disturbs the quantum statistics. Also what makes bosons to have same quantum states?
 A: Let $\psi(x_1,\,x_2)$ denote the mutual wavefunction of two identical particles, where the vectors $x_i$ bundle up one particle's state's quantum numbers. Exchanging the particles changes the amplitude to $\psi(x_2,\,x_1)$. The linear operator that changes $\psi$ in this way squares to the identity (since a second swap recovers $\psi(x_1,\,x_2)$), so its eigenvalues are $\pm 1$. Bosons achieve an eigenvalue of $+1$, with something of the form $\psi(x_1,\,x_2)=(\phi(x_1,\,x_2)+\phi(x_2,\,x_1))/\sqrt{2}$. For fermions, the eigenvalue is $-1$ and the $+$ between the $\phi$s becomes a $-$. But then $\psi(x_1,\,x_1)=0$, and there's no chance of both fermions having the same state.
A: A beautiful question that every quantum mechanics student asks eventually. Glad you did too.
To be very brief, the answer to your question is not very easy. The solution lies deep within the heart of Quantum Field Theory (QED) in a theorem known as Spin-Statistics Theorem (SST) first explicitly and conclusively proven by Pauli. I will try and lay out the full proof of why fermions and bosons act the way they do, so that you can refer to the actual argument and appreciate the beauty in it.
Remember throughout the answer that - fermions are "defined" as those particles whose wavefunctions anticommute and bosons are "defined" as thosse particles which commute.
From QFT : Relativistic causality requires quantum fields at two spacetime points $x$ and $y$ separated by a spacelike interval $(x-y)^2<0$ to either commute or anticommute with each other.
Statement of SST: Fields of integral spins (bosons) commute while fields of half-integral spins (fermions) anticommute.
We will be proving the above statement for dimension $d=4$ because for $d\ne4$ its excessively complex (exotic spin states occur but we won't go into that).
Assumptions : 


*

*The fields are Lorentz Invariant.

*The excitations of the fields (particles) have positive energies.

*All the states have positive norm (avoiding ghost particles which have wrong spin statistics).


Proof : 
We will consider a generic Lorentz multiplet of quantum fields $\hat{\phi}_A$ whose quanta have spin $j$ and mass $M$. Free fields satisfy some kind of linear equations of motion which have plane wave solutions with $p^2=M^2$. Let $p^0=+\sqrt{\textbf{p}^2+M^2}$ and let $e^{-ipx}f_A\left(\textbf{p},s\right)$ and $e^{+ipx}f_A\left(\textbf{p},s\right)$ be respectively the positive frequency and negative frequency solutions The $s$ here labels different wave polarizations for same $p^\mu$ : spin states for $M>0$ or helicities for $M=0$.
The main outlook for us are the following two definitions and the two lemmas relating them. 
(For now, please take these lemmas to be true, this answer will get excessively big if we show those proofs also. But I assure you that they are well proven facts and require just the first three basic assumptions.) 
The definitions : 


*

*$$F_{AB}=\Sigma_s f_A(\textbf{p},s)f^*_B(\textbf{p},s)$$

*$$H_{AB}=\Sigma_s h_A(\textbf{p},s)h^*_B(\textbf{p},s)$$


And the relations :


*

*Both $F_{AB}\left(p\right)$ and $H_{AB}\left(p\right)$ can be analytically continued to off-shell momenta as polynomials in the four component of $p^\mu$ 

*These polynomials are related to each other as  :


$$
\begin{array}{rcll}
H_{AB}\left(-p^\mu\right) & = & +F_{AB}\left(+p^\mu\right) & \text{for integral spin} \\
%
H_{AB}\left(-p^\mu\right) & = & -F_{AB}\left(+p^\mu\right) & \text{for half-integral spin}
\end{array}
$$
A free quantum field is a superposition of solutions with operatorial coefficients, thus:
$$
\begin{array}{ccc}
\hat\phi_A(x) & = & \int \frac{\mathrm{d}^3p}{(2\pi)^3}\frac 1{2E_\textbf{p}}\Sigma_s{\left[e^{-ipx}f_A(\textbf{p},s)\hat a\left(\textbf{p},s\right) + e^{+ipx}h_A(\textbf{p},s)\hat b^\dagger(\textbf{p},s)\right]}_{p^0=+E_\textbf{p}} \\
%
\hat\phi^\dagger_B\left(y\right) & = & \int \frac{\mathrm{d}^3p}{(2\pi)^3}\frac 1{2E_\textbf{p}}\Sigma_s {\left[e^{-ipy}h^*_B(\textbf{p},s)\hat b(\textbf{p},s) + e^{+ipy}f^*_B(\textbf{p},s)\hat a^\dagger(\textbf{p},s)\right]}_{p^0=+E_\textbf{p}}
\end{array}
$$ 
Regardless of statistics, positive particle energies require $\hat a^\dagger \left(p,s\right)$ and $\hat b^\dagger \left(p,s\right)$ to be creation operators while $\hat a \left(p,s\right)$ and $\hat b\left(p,s\right)$ to be annihilation operators. Thus,
$$
\begin{array}{ccccc}
\hat a^\dagger (\textbf{p},s) \left|0\right> & = & \left|1(\textbf{p},s,+)\right> \\
\hat b^\dagger (\textbf{p},s) \left|0\right> & = & \left|1(\textbf{p},s,-)\right> \\
\hat a (\textbf{p},s) \left|0\right> & = & \hat b (\textbf{p},s) \left|0\right> & = & 0
\end{array}
$$
Hence in a Fock space of positive-definite norm : 
$$\left< 0\ \middle|\ \hat a(\textbf{p},s)\hat a^\dagger (\textbf{p}',s')\ \middle|\ 0 \right> = \left< 0\ \middle|\ \hat b(\textbf{p},s)\hat b^\dagger (\textbf{p}',s')\ \middle|\ 0 \right> = +2E_\textbf{p}(2\pi)^3 \delta^{(3)}(\textbf{p}-\textbf{p}')\delta_{s,s'}$$
while all other "vacuum sandwiches" of two creation/annihilation operators vanish identically. Therefore, regardless of statistics, vacuum expectation values of two fields at distinct points $x$ and $y$ are given by:
$$
\begin{array}{rcl}
\left< 0\ \middle|\ \hat\phi_A(x)\hat\phi^\dagger_B(y)\ \middle|\ 0 \right> & = & +\int \frac{d^3\textbf{p}}{(2\pi)^3}\frac 1{2E_{\textbf{p}}}e^{-ip(x-y)} \times \Sigma_s f_A(\textbf{p},s)f^*_B(\textbf{p},s) \\
%
\left< 0\ \middle|\ \hat\phi^\dagger_B(y)\hat\phi_A(x)\ \middle|\ 0 \right> & = & +\int \frac{d^3\textbf{p}}{(2\pi)^3}\frac 1{2E_{\textbf{p}}}e^{+ip(x-y)} \times \Sigma_s h_A(\textbf{p},s)h^*_B\left(\textbf{p},s\right)
\end{array}
$$
At this point, just a bit more algebra using those definitions and the first lemma is all that is left. Further calculating :
$$\langle 0\ |\ \hat\phi_A(x)\hat\phi^\dagger_B(y)\ |\ 0 \rangle = +\int \frac{d^3\textbf{p}}{(2\pi)^3}\frac 1{2E_{\textbf{p}}}e^{-ip(x-y)} F_{AB}(p) |_{p^0=+E_\textbf{p}}=F_{AB}(+i\partial_x)D(x-y)$$
where :
$$D(x-y) = +\int \frac{d^3\textbf{p}}{(2\pi)^3}\frac 1{2E_{\textbf{p}}}e^{-ip(x-y)}|_{p^0=+E_\textbf{p}}$$
and $F_{AB}(+i\partial_x)$ is a differential operator constructed as an appropriate polynomial of $i\partial/\partial x^\mu$ instead of $p_\mu$. Likewise :
$$\left< 0\ \middle|\ \hat\phi^\dagger_B(y)\hat\phi_A(x)\ \middle|\ 0 \right> = +\int \frac{d^3\textbf{p}}{(2\pi)^3}\frac 1{2E_{\textbf{p}}}e^{+ip\left(x-y\right)} H_{AB}\left(p\right)|_{p^0=+E_\textbf{p}} = F_{AB}(-i\partial_x)D\left(y-x\right)$$
Relativity demands that for a spacelike interval $x-y$, $D(y-x)= +D(x-y)$. At the same time, we also have the relation of the second point of the lemmas. Therefore, regardless of statistics :
$$
\begin{array}{cccl}
\left< 0\ \middle|\ \hat\phi_A(x)\hat\phi^\dagger_B(y)\ \middle|\ 0 \right> &=& +\left< 0\ \middle|\ \hat\phi^\dagger_B(y)\hat\phi_A(x)\ \middle|\ 0 \right> & \text{for particles of integral spin} \\
%
\left< 0\ \middle|\ \hat\phi_A(x)\hat\phi^\dagger_B(y)\ \middle|\ 0 \right> & = & -\left< 0\ \middle|\ \hat\phi^\dagger_B(y)\hat\phi_A(x)\ \middle|\ 0 \right> &  \text{for particles of half-integral spin}
\end{array}
$$
On the other hand, relativistic causality requires for $\left(x-y\right)^2<0$  :
$$
\begin{array}{cccl}
\left< 0\ \middle|\ \hat\phi_A(x)\hat\phi^\dagger_B(y)\ \middle|\ 0 \right> & = & +\left< 0\ \middle|\ \hat\phi^\dagger_B(y)\hat\phi_A(x)\ \middle|\ 0 \right> & 
 \text{for bosonic fields} \\
%
\left< 0\ \middle| \ \hat\phi_A(x)\hat\phi^\dagger_B(y)\ \middle| \ 0 \right> & = & -\left< 0\ \middle|\ \hat\phi^\dagger_B(y)\hat\phi_A(x)\ \middle|\ 0 \right> & 
 \text{for fermionic fields}
\end{array}
$$ 
And the only ways the above couple of pairs of equations hold true together are if all particles of integral spins are bosons and all particles of half-integral spins are fermions.
And this completes our proof.
And if you now work out the commutators of the quantum fields of the particles, you will see a term of the form $(-1)^{2j}$ pop up, where $j$ is the spin of the particle. And thus you see why bosons take a value of $+1$ and fermions take $-1$ !
For the rest of the argument, I will gladly direct you to the beautiful answer of J.G.
Cheers!!  
A: The earlier answer explained that the exclusion principle is a consequence of antisymmetric wavefunctions.  To broaden the intellectual map, I’d like to mention the arguments that relate three further concepts:  symmetry or anti-symmetry of the wavefunction, integer or half-integer spin, and positivity of energy.  
Dirac’s wave equation describes particles that have two spin states and positive or negative energy, $E=\pm \sqrt{{{p}^{2}}+{{m}^{2}}}$.  The negative-energy states must be full to capacity, lest it be possible to extract further energy from the vacuum, which ought to be the state of minimum energy.  This demands exclusion. 
Pauli came up with a clever argument that related the anti-symmetry of wavefunctions under interchange of positions to half-integer spin.  The key is that interchange of identical particles at $x=+1$ and  $x=-1$  is equivalent to a 180-degree rotation around the z-axis, and that such rotation of particles with ${{S}_{z}}=\tfrac{1}{2}$ will introduce a phase factor of $i$  for one or ${{i}^{2}}=-1$ for the two of them.  
There are also algebraic arguments to the effect that Dirac fields must be quantized with anti-commuting operators, and scalar or vector fields with commuting operators, to avoid acausal propagation outside the light cone.  
