For example, could a Giant Ape with one arm still use Multiattack even though it is listed as "two fist attacks"?
Theoretically, yes, a creature could still Multiattack while missing a limb
Take, for example, a level 5 Fighter that uses Sword&Board, i.e. they fight with a Longsword (or some other one-handed weapon) and a Shield. In a given turn, they're permitted to make two attacks with their Action, one normally, and one permitted by their Extra Attack feature. This happens despite the fact that they're still only attacking with one weapon, held in one hand. If this same fighter were to lose an arm, they'd choose whether to stop wielding a weapon or stop wielding their shield; but they'd still be permitted to make two attacks each turn.
Same with the ape: the abstractions of the game mean that losing an arm doesn't necessarily mean they lose one of their attacks, because the rules don't expressly say that they do.
In contrast, consider the Hydra, whose Multiattack feature expressly describes it as "having as many attacks as it has heads":
Multiple Heads. The hydra has five heads. While it has more than one head, the hydra has advantage on saving throws against being blinded, charmed, deafened, frightened, stunned, and knocked unconscious.
Multiattack. The hydra makes as many bite attacks as it has heads.
—Hydra, Monster Manual, pg. 190
So because some creatures explicitly stipulate how many attacks they have as proportional to the number of "limbs" (heads) they have, whereas a Giant Ape does not, it's possible to interpret these statblocks as implying that the loss of a single limb does not penalize their normal mechanism of attack.
The DM is empowered to make on-the-fly rulings on this matter
I certainly believe it is reasonable to impose some kind of handicap on a creature that is missing a limb. For a Giant Ape, if it lost one of its arms without straight-up dying in the process, then I might, as DM, remove one of its attacks each round or impose disadvantage on their attacks. But this would be a personal decision, and a DM is not required to support this ruling.
This would be a lot more clear-cut if we were taking about, say, a Humanoid wielding a greataxe: they definitely would not be able to fight using their normal statblock if they were missing an arm; if I were to even allow them to keep using the Greataxe in the first place. But I would also probably allow that creature to keep making multiple attacks if they instead switched to a one-handed weapon.
So this is ultimately a situation that comes down to your DM. The DM is empowered to make debilitating conditions (like losing an arm) come with mechanical penalties; but it's not strictly required for a DM to adjudicate that losing an arm means losing one of the attacks in a Multiattack, unless the statblock for the creature expressly says it would.
Depends on the specific limb and multiattack
There is an optional rule called "Injuries" (DMG p272), and two of the listed injuries are relevant:
Lose an Arm or a Hand. You can no longer hold anything with two hands, and you can hold only a single object at a time. Magic such as the regenerate spell can restore the lost appendage.
Lose a Foot or Leg. Your speed on foot is halved, and you must use a cane or crutch to move unless you have a peg leg or other prosthesis. You fall prone after using the Dash action. You have disadvantage on Dexterity checks made to balance. Magic such as the regenerate spell can restore the lost appendage.
Neighter of those injuries limits the number of attacks the injured character can make. However, those optional injuries are clearly meant for humanoids and there is no general rule for what other creatures missing a limb can or cannot do. Even the Sword of Sharpness doesn't attempt to list the effects of losing a limb:
Then roll another d20. If you roll a 20, you lop off one of the target's limbs, with the effect of such loss determined by the DM.
That said, there are some cases where the anatomy of creature comes into play. For example:
A Giant Crocodile cannot multiattack if it is missing its only tail
Multiattack. The crocodile makes two attacks: one with its bite and one with its tail.
Because the crocodile can't possibly attack with something it does not have.
A Giant Subterranean Lizard can multiattack if it is missing its only tail
So long as it chooses to replace its tail attack with a Swallow:
Multiattack. The lizard makes two attacks: one with its bite and one with its tail. One attack can be replaced by Swallow.
A Giant Ape can Multiattack if it is missing an arm
So long as it chooses to make both attacks with the same fist:
Multiattack. The ape makes two fist attacks.
Because "two fist attacks" does not necessarily mean "two attacks with distinct fists".
Moreover, while there are no general rules for missing limbs, there some rules that require hands, like the rules for Grappling: a two-armed Giant Ape can doubtlessly hold a grappled foe with one hand and multiattack with the other fist, but a one-armed Giant Ape can't do the same.