Compartmentalized biochemical reactions are a ubiquitous building block of biological systems. The interplay between chemical and compartmental dynamics can drive rich and complex dynamical behaviors that are difficult to analyze mathematically — especially in the presence of stochasticity. We have recently proposed an effective moment equation approach to study the statistical properties of compartmentalized biochemical systems. So far, however, this approach is limited to polynomial rate laws and moreover, it relies on suitable moment closure approximations, which can be difficult to find in practice. In this work we propose a systematic method to derive closed moment dynamics for compartmentalized biochemical systems. We show that for the considered class of systems, the moment equations involve expectations over functions that factorize into two parts, one depending on the molecular content of the compartments and one depending on the compartment number distribution. Our method exploits this structure and approximates each function with suitable polynomial expansions, leading to a closed system of moment equations. We demonstrate the method using three systems inspired by cell populations and organelle networks and study its accuracy across different dynamical regimes.