Acetone on foam always makes it dissolve. It will be uneven. Sanding might be Ok if the foam particles are tiny. But I know that theaters carve foam with a hot wire. Low voltage across a fairly fine piano wire bent into the shape you want.