First-principles calculation of crystal field parameters of Dy ions substituted for Nd in Nd-Fe-B magnets