What is the significance of the linear phase in the phase response of an M-point moving average filter?
The significance is a constant time delay for all frequencies. Time delay is the derivative of phase with respect to frequency, so given a linear phase as shown, the time delay is constant. Notice that the abrupt steps in phase actually only occur when the magnitude goes through zero so does not effect the nature of it being a &quot;linear phase&quot; filter.
An M-point moving average filter will have a time-delay (for all frequencies) of $M/2$, so if you increase the number of points, the phase slope versus frequency will increase.
Why do we like linear phase filters so much? Please see this post on that:
Why is a linear phase important?
Any finite impulse response (FIR) filter with symmetric or anti-symmetric coefficients (The OP's case with coefficients all 1 is symmetric) will be a linear phase filter.