Resource guarding is aggressive behavior over food, treats, toys, objects, space and even humans. To avoid it you need to teach your dog to trade something good for something better. While very important in avoiding resource guarding, the trading technique can literally be a lifesaver in emergency situations when a dog tries to chew or consume something that could be harmful.
Present your dog with a low value toy. When he goes to take it, say 'take it' and allow him to play with it. Present him with a duplicate that you have behind your back. As he drops the object in his mouth, say 'drop it' and reward him with the duplicate that you have in your other hand, saying, 'take it.' Repeat this exercise frequently.
Up the Ante
When your dog is consistently complying, build up the value of the toy. If he does not want to give up the higher-value toy, walk away, show him a new toy, and direct all your interest to the new toy, playing with it. Typically, curiosity will lead him to come over and give up the toy he has in his mouth. Immediately reward his decision by giving him the new toy and repeating the 'take it,' 'drop it' sequence.
It is very important to work on this with your dog during play time and NOT at meal time at his dish. Always end these exercises by giving the original toy back so it is a positive experience for him. Never become angry, dominating or forceful if the dog does not comply. Meeting aggression with aggression escalates the situation. Consult a professional POSITIVE trainer if this becomes a problem to learn how to manage his environment until his behavior is modified.