Okay, here we go!
When an ear detects a sound wave, it comes to a compression in the one and rarefaction in the other hand. The sound wave is segmented in wavelengths and their distance to each other influence the frequency. Compression causes a shorter distance of the wavelengths, a higher frequency and a louder sound, while a rarefaction leads to a longer distance of the wavelengths, a lower frequency and a quieter (softer) sound.