>

Dogs don't really understand it because we give them their food, so in their logic we can provide them with any food we have at hand. Even if we don't eat the same thing dogs are scavengers that rely on humans for getting food. Begging is a normal behaviour because it's part of the "seeking for food" process.
But their food is their food. It's their resource, and when they feel it is endangered they try to protect it. Since dogs are not pack animals, they don't share, they might even try to steal other dog's food.
Have you ever stood close to your dog and watched them as they ate. Some untrained dogs may growl or snap at you, while other dogs may refuse to eat until you leave or will take their food to another location, probably their cage. Why? Because it’s uncomfortable and they feel like you’re intruding on their meal time or may even think you’re trying to steal their food from them. So if a dog realizes there’s something why can’t a human.
A well trained dog will understand that your food is your food and his food is his food