Direct construction of stellarator-symmetric quasi-isodynamic magnetic configurations