Yes, it's to protect the travel company or the airline from problems and complaints. I expect our embassies abroad are keen on it too, for the same reasons. EasyJet are very keen on you buying theirs every trip, which is extra profit for them, so if your travel operator is offering their own you might think it wise to shop around!.
It's conceivable that a particular foreign country requires travel insurance of all tourists brought in by operators, but it seems very unlikely. The USA patently doesn't and they are very keen on refusing entry to anyone, it always seems ..
It's surely unwise to travel abroad, particularly to somewhere like the Maldives, without at least health insurance which provides for local care and repatriation , if necessary. You may have such cover anyway, if you have paid using certain cards ( my American Express card provides it, for example) but check first on what, if any, cover that is ! Adequate cover for an ordinary holiday can't cost much.