It's difficult to know without knowing exactly what it is, but in general, "foam" just absorbs high frequencies. The issue in most rooms is low frequencies. Foam can look nice, but it usually does either nothing, or can even make the problem worse. For effective room treatment, you need broadband absorption, and most foam products won't do that. There are tons of sites with info about this on the web, just do a search and prepare for hours of reading. Here's a reasonable high level introduction:
https://ehomerecordingstudio.com/aco...treatment-101/
and another:
https://www.soundonsound.com/techniq...stic-treatment
These are just basic starting points.