Select each polygon and apply a suitable 3D modeling to it:
Adjust the modeling of the polygons until one arrives at the desired effect.
Select each element of the flag and assign a suitable 3D modeling effect:
Then remove the surround material from the model: