The ring imaging Cherenkov detector of the NA62 experiment at CERN