Yes, an animal companion can and should wear armour (but it will want to invest feats in armour proficiency)
Pretty much anything can wear armour (often referred to as barding when meant for animals), and it gains the benefit of the armour as usual, whatever kind of armour that is. It's generally a good idea to invest in armour for animal companions because it improves their survivability on the front line - I would expect a high-level druid or ranger's companion to be wearing magical armour, in fact. However, in order to avoid suffering the armour check penalty on attacks, the creature needs to have proficiency with the class of armour in question:
Nonproficient with Armor Worn: A character who wears armor and/or uses a shield with which he is not proficient takes the armor’s (and/or shield’s) armor check penalty on attack rolls as well as on all Dex– and Str-based ability and skill checks.
To avoid the penalty, the gorilla will need the Armor Proficiency feat for the armour category in question. Animal companions gain feats as they gain HD, as listed in the progression table for animal companions, and the Armor Proficiency feats are even on the list of recommended animal companion feats. However, even without the proficiency, the gorilla can still wear the armour - it'll just suffer a penalty on attack rolls while it does. Some armours may not actually have an armour check penalty, like masterwork studded leather, so a creature without proficiency could still wear that without any penalty.
The Armor for Unusual Creatures table gives a method for calculating the price of making armour for differently sized creatures. Armour for animals is often called "barding" rather than "armour", but in game terms barding is just another word for armour for a non-humanoid creature - a gorilla is probably sufficiently non-humanoid (with drastically different proportions to normal humanoid-type creatures) that the more expensive version is needed, but that's your jurisdiction. You should keep in mind that most animal companions increase a size category at some point in their progression (for the "Ape" companion you're probably using to represent a gorilla, that's at 4th level); armour made for the companion before it increases in size will no longer fit on the larger creature and a new set would have to be made.