Learning to correct spectral methods for simulating turbulent flows