Thank you for your query.Hope this answers your query.
I think he has hurt his tendons of the extensor muscles of the knees or he has a suprapatellar bursitis
Give him a rest,elevate his knees and apply ice packs to the local area.
Give him an analgesic-muscle relaxant
for a few days.
If the pain persists then consult an orthopedician.
If you have any other queries kindly direct them to me.Wishing your child a speedy recovery.Have a nice day.