A. A visit to your Pediatrician would be a very good idea. If he could stop doing this on his own, he likely would have already. And punishing him or bribing him is not likely to be helpful.
The most common cause of symptoms like this is encopresis, a complication of being constipated. Children who become severely constipated can sometimes not sense when they need to have a bowel movement and so can have an involuntary leakage of stool.
Has he been constipated?
When he goes to 'poop in the toilet,' is it very big and hard or like little, hard pellets? If so, then he likely is constipated.
And if he is constipated, then it may help to increase the amount of fluids, fiber, and bran in his diet, and avoid a lot of constipating foods, like whole milk and bananas. He would likely also need a stool softener.
Another part of the treatment for both constipation and encopresis is for your child to begin having regular bowel movements each day. You might even start a schedule where he sits and tries to go several times throughout the day, especially in the morning, after school, after dinner, and before bed. It is usually best to have him sit on the commode for about 3 to 5 minutes about 5 to 20 minutes after a meal, since that is when children are most likely to have a bowel movement.
Even if he doesn't have constipation or encopresis, a more regular routine of having bowel movements could help.

