Crystal and magnetic structures of Nd2Ni2Sn and Dy2Ni2Sn compounds