States near Dirac points of a rectangular graphene dot in a magnetic field