While reading the Princeton Companion to Mathematics, I came across the following sentence in the article related to Riemann:
The Riemann integral remained the dominant definition of the integral until it was replaced by the Lebesgue Integral after 1902, which is better adapted to capturing the way the behavior of a function affects its Fourier series.
Can someone explain how does the Lebesgue integral more suited to study Fourier Series?
The most prominent reason in that context is that, with the Lebesgue integral, you get spaces of functions on which the integral induces norms which make these spaces into Hilbert or Banach spaces, e.g. $$||f||_2 := \left( \int |f|^2 \right)^{1/2}$$
In particular they are complete as normed spaces, which allows you to invoke the machinery of linear functional analysis. Specifically the Fourier series is nothing but an expansion of a function by an orhtonormal base in the space of square integrable functions.
The Riemann integral coincides with the Lebesgue integral whenever it is defined, so at first sight you may not be able to appreciate the difference. It has, however, poor properties when it comes to questions like 'is the limit of a series (w.r.t. a suitable norm) again integrable'?