2D prodicity

Hi every body

I have built a 3D periodic box of a polymer.How i can change it to a 2D periodic polymer that polymer enclose whitin a rectanguler prism simulation box?

I want to have a 2D periodic RVE whit periodic condition along X and Y and no periodicity along Z. I do not to make a surface.

Regards