Converting PDM Data to analog
What is the theory of behind the low pass filter can average of signal? Can you explain this situation with mathematically through RC Low Pass Filter?

A low-pass filter lets through signal at 0 Hz (otherwise it wouldn't be called a low-pass).
The 0 Hz of any signal is its average.

How can the low pass filter do that?

It lets through low frequencies – that has the above-mentioned averaging effect. That means that at the output of a low-pass filter of sufficiently low cut-off frequency you don't notice the on/off of the PDM – you just see the average weighted over the whole impulse response duration of that filter.
If you want more details, you'll need to understand how frequency response and impulse response relate – but that's really the central thing in every &quot;systems and signals&quot; textbook, so I don't think I could contribute anything to that by writing it in an answer.

Can we say this &quot;Low pass filters filtering almost (not clearly) all harmonics except Fourier first coefficient?

No. &quot;first Fourier coefficient&quot; assumes that there's countably many Fourier coefficients, i.e. a discrete Fourier Series. Only periodic signals have such, your signal is not periodic, hence there's no &quot;first Fourier coefficient&quot;; your PDM signal has a continuous spectrum.
I'm not sure this is the case, but my guess is really you only need a refresher on what a (continuous) Fourier transform is.