ER-20 is designed for more uniform SPL reduction across all frequency so you can hear sound safely yet clear enough in an noisy environment (like rock concert). If you use a foam plug, you will lose more treble (= detail). However, If all you want is noise isolation than foam plugs will indeed be better.
If I wanted pure volume reduction, no doubt I'd pick dense yellow foamies. But for actually being ablt to maintain normal hearing, I'd pick my ER-16s anytime, and ill replace them with ER-20s the day that I lose them.