How can we visualize that $2^n$ gives the number of ways binary digits of length n? Like if we have to find the number of ways can be represented in bits up to 4 places. We use $2^4$, but why do we use this method?

Because for each bit you have 2 different simbols. 
Then if $n$ denotes the number of bits, this means that we have to make a choice between $1$ or $0$ for $n$ times is:
$$\underbrace{2\cdot2\cdot2\cdot\dots\cdot2}_{n\text{-times}}=2^n$$
This happens because every choice is independent from the others. 
If you want you can prove it easily by induction.
