Proof by induction.
When $n=0$ then $\mathcal P(\emptyset)=\{\emptyset\}$ so $|\mathcal P(\emptyset)|=1.$
Now, assume it is true for all $|S|=n,$ and assume $|T|=n+1.$
Pick one element $x\in T.$ Then let $T_0=T\setminus \{x\}.$ We have $|T_0|=n.$
Then for every $M\subseteq T_0$ there are exactly two subsets of $T,$ $M$ and $M\cup\{x\}.$
So $$|\mathcal P(T)|=2|\mathcal P(T_0)|=2\cdot 2^{n}=2^{n+1}.$$
We could be alightly more rigorously prove this by defining a function $f:\mathcal P(T)\to \mathcal P(T_0)\times \{1,2\}$ and prove it is a bijection.
We define, for $M\subseteq T,$ $$f_2(M)=\begin{cases}1&x\in M\\2&x\notin M
\end{cases}$$
Then $f(M)=(M\cap T_0,f_2(M)).$
Showing this is a bijection is tedious work, but direct.