We present a molecular simulation study with the aim of investigating the structural phase transition of ZJU-198 metal-organic framework. This material has been recently synthetized with the appropriate control of window size, which performs well for the separation of mixtures of gases containing nitrogen and methane. We find that the adsorption of small gases in this structure is unusual, and provide an explanation of the molecular mechanisms involved. Using molecular simulation, we analyze the structural distortions exerted by the adsorption of carbon dioxide, nitrogen, methane, acetylene, and ethene. We found that the separation of mixtures composed of these gases in ZJU-198 is due to the organic linker of the structure. The rotation of this linker causes the expansion of the cavities and enhances gas separation by allowing the adsorption of molecules that a priori are too big to be adsorbed.