Accurate modelling of nozzle expansion and associated phase-change processes of CO \(_2\) is critical for optimal design of CO \(_2\) ejectors for refrigeration and air-conditioning systems. The study evaluates the performance of the homogeneous equilibrium model (HEM) in simulating the two-phase flashing nozzle flow of CO \(_2\) for different divergence angles and for subcritical and supercritical inlet conditions. The study also applies the HEM to simulate the transcritical CO \(_2\) flow in a two-phase ejector under various conditions. For nozzle flow at small divergence angles, the prediction of HEM is closer to the experimental data and superior to that of the mixture model. The accuracy of HEM decreases for drastic expansions of CO \(_2\) , and the reason for the inadequate prediction of pressure and temperature in such scenarios is be explained by a critical analysis of the phase transformation process. It is found that the accuracy of the HEM simulations depends on the nozzle geometry. The numerical results for the ejector flow show good agreement with the experimental data. The results for the single and double-choking cases show variations closely related to the shock properties and the mixing process. The study represents the first attempt to investigate the mixing process of the flows in the ejector from the perspective of thermal energy transfer in addition to momentum transfer.