Structure and refractive parameters of doped K$_2$SO$_4$ crystals