why the number of filter coefficients in FIR filter has to be an odd number?
There is no such requirement. However, for linear-phase (symmetric) FIR filters, the delay can be expressed as:

$$
D = \frac{order}{2} = \frac{N_{taps} - 1}{2} \text{ samples}
$$

If the number of taps is odd, then the delay of the filter is an integer number of samples, which is desirable for some applications. If you have an even number of taps, then you end up with a half-sample delay.