Sound is a wave. More specifically, sound is defined to be a disturbance of matter that is transmitted from its source outward.
As the stringoscillates back and forth, part of the string’s energy goes into compressing and expanding the surrounding air. This creates slightly higher and lower pressures.
The higher pressure... regions are compressions, and the low pressure regions are rarefactions.
The speed of sound varies greatly depending upon the medium it is traveling through. The speed of sound in a medium is determined by a combination of the medium’s rigidity (or compressibility in gases) and its density.
The more rigid (or less compressible) the medium, the faster the speed of sound.