Harmonics in the excitation current of Transformer is due to Hysteresis. As we know the relationship between Magnetic Flux Density, B and Magnetic Field Intensity, H is not linear as shown in figure below.

Also,

B = Flux (Ø) / Area (A),

and H = NI

where N = Number of turns and I = Magnetizing Current

Therefore, there exist hysteresis relationship between Flux and Magnetizing Current. The Transformer is preferably operated in saturation region which in turn means that for considerable increment in current causes a slight increase in flux, which gives flux wave sinusoidal shape, while magnetizing current is peaky. This explains why it is rich in 3rd harmonic component even though the supply is sinusoidal.

If we observe the waveform of excitation current of Transformer, we see that the wave form of current is symmetrical which means absence of even harmonics. Remember that waveform will not be symmetrical if there is any even harmonic component.

The peaks of the magnetizing current and flux will occur simultaneously, while their zeros will not, due to hysteresis.

Thus I hope it is clear that how harmonic component comes in the excitation current of Transformer.