Hi there! Welcome to BYC.
Diatomaceous earth kills arthropods because it contains silica. At a microscopic level, silica is razor sharp and works by “slicing open” the protective layer of their shell to slowly dry them out until they die.
The internal organs of a chicken are, of course, wet, so DE will do absolutely nothing to affect a parasite load inside of a chicken’s gut.
It may be beneficial to prevent mites if you add it to their dust bathing areas, but be aware that chickens have sensitive respiratory systems and DE tends to be very dusty.
As far as deworming goes, it is typically not needed in the average backyard flock. Chickens are designed to handle some amount of parasite load in their gut without being effected.
A veterinarian can run an inexpensive fecal float test to check for parasites in their poop. If you decide to worm, you need a proper medication such as ivermectin or valbazen.