Intervals are the building blocks of melody and harmony, …

https://www.musical-u.com/learn/what-is-an-interval/
Intervals are the building blocks of melody and harmony, and learning to recognise the different types of interval can help you understand harmony, transcribe melodies, and play by ear. It powers your sense of relative pitch, a fundamental musical ability. https://www.musical-u.com/learn/what-is-an-interval/