This article investigates power sharing and power quality improvement issues of islanded single-/three-phase microgrids (S/T-MGs) where both sources and loads are unbalanced. A hierarchical distributed control approach is proposed, which consists of 1) a phase-independent virtual synchronous generator (P-VSG) control used for primary control of distributed generators (DGs), 2) a distributed secondary power flow regulator used for power sharing control among DGs and among phases, and 3) a distributed secondary voltage regulator used for voltage restoration and power quality improvement. Compared with conventional methods, the proposed control has several salient features: 1) the P-VSG control allows for independent and flexible power control and voltage regulation for each phase and accurate phase shifts; 2) distributed containment control proposed in the secondary power control and voltage regulation layer guarantees admissible output phase powers, voltage profiles and power quality; 3) the constraint operator developed for the secondary controllers makes charging/discharging power of the energy storage system (ESS) within permitted values; 4) communication delays are also considered in the proposed distributed approach. Simulation results are presented to demonstrate the proposed control method.