Sonos released the update only for current speakers, so AirPlay 2 is only available for the Sonos One, Playbase, Beam, and the second generation Play: 5. However, if you have in addition an older Sonos speaker in your home, then you can group it with a compatible speaker and also enjoy AirPlay 2.
How to Upgrade a Sonos Speaker for AirPlay 2
First, open the Sonos app on your iPhone. At the bottom right, tap on the "More" tab. At the top you should now be informed that an update is available. To do this, tap the white Update button and then confirm your entry again. If you have not yet installed version 9.0 (or newer) of the Sonos app on your iPhone, you will now be redirected to the App Store for update.
After installing the app update, reopen the Sonos app. You will now be presented with the "Search for Updates". Then tap "Update" to perform the update. If the attempt fails, tap Try Again. Once the update is installed, you will be presented with a Welcome screen to AirPlay. Touch Done. You can now tap the AirPlay icon in the Music app, podcast app, and many other apps and play the sound on your Sonos speaker. The Sonos app is no longer required for playback.