Optimization of detector modules for measuring gamma-ray polarization in Positron Emission Tomography