Is it safe to give children Benadryl (diphenhydramine) to sleep when they're 10yo?

Sleep. No. Benadryl (diphenhydramine) or Diphenhydramine can stick to the brain for 3 days impairing motor and skilled performance, judgment and memory etc.
Yes if used seldomly. Plain Benadryl (diphenhydramine) is safe to use in children to treat allergy symptoms such as hives or other itchy rashes, itchy / watery eyes, and itchy / sneezy / runny noses. Benadryl (diphenhydramine) makes most kids drowsy, so it is safe for occasional use as a sleep aid, such as when cold symptoms prevent one from falling asleep. Children should not need sleep aids on a regular basis, unless prescribed by a pediatrician.