On a dual function of anions in crystallogenesis of compounds: Structure-directing and stabilizing