Cohomological localizations and set-theoretical reflection