Well I don't think you are thinking about this in from a lore standpoint, which they may be. For example, the Meat Golem is clearly an intelligent enough creature and it may know magic of which lets it cast that spell, who knows what they did to that thing or what it was before it was a meat golem.