From DOTA 2 wiki I read that the hero Shadow Fiend has 6 abilities, Broodmother has 7 abilities, and Invoker has 14 abilities in total. Is it true that if a hero in DOTA 2 has 6 abilities or more, then we are only allowed to choose 4 of those abilities ?
As a general rule of thumb, each hero has 4 abilities - 3 basic abilities and 1 ultimate ability. Every hero has at least 3 basic abilities and 1 ultimate ability.
Some heroes, such as Shadow Fiend and Broodmother, have sub-abilities. These are associated with 1 or more of the basic abilities. For example for Shadow Fiend, Shadowraze (Medium and Far) are associated with Shadowraze (Near), and for Broodmother, Destroy Spin Web is associated with Spin Web. Technically speaking Broodmother only has 5 abilities, since Poison Sting and Spawn Spiderite aren't her abilities but are the Spiderites'. Troops created by your abilities may have their own abilities, separate from the heroes.
Invoker is a very unique hero in that his ultimate ability, Invoke, can create up to 14 spells. I view these spells as abilities. However people generally refer to his basic abilites as "instances" and those sub-abilities as "spells." He can only have up to 2 spells at once aka 6 in total. He always has access to his instances and Invoke. He can also replace one of his spells with another one during the game, as many times as he wants. This is fairly complicated for a hero, and understandably Invoker is considered one of the hardest heroes to master!
So technically speaking, no you do not only choose 4 abilities when you have >4. For those heroes with extra abilities, you generally get them all at once, with Invoker being somewhat of an exception. But it's much easier to understand how they work if you play those heroes through a full game than reading on a wiki page.