Interwar there were attempts to limit submarine operations against merchant shipping in light of the WW1 unrestricted campaigns by Germany.
Alongside the main 1922 Washington Treaty was the "Treaty relating to the Use of Submarines and Noxious Gases". It sought to impose rules on the use of submarines against merchant shipping, effectively outlawing it. This Treaty did not come into effect because France refused to ratify it.
Then the 1930 London Treaty imposed limits on submarine tonnage available to Britain , US and Japan. 52,700 tons each (Article XVI). Tonnage limit per sub 2,000 tons and 5.1" gun BUT each nation could have up to 3 of up to 2,800 tons with up to 6.1" guns (allowing Britain to keep the X1 but France got to keep Surcouf) and keep anything already completed of less than 2,000 tons with guns above 5.1". But all within the overall tonnage limit. Replacement age was 13.
Article XXII sought to limit the war on merchant shipping including by submarines.
"The following are accepted as established rules of International Law:
(1) In their action with regard to merchant ships, submarines must conform to the rules of International Law to which surface vessels are subject.
(2) In particular, except in the case of persistent refusal to stop on being duly summoned, or of active resistance to visit or search, a warship, whether surface vessel or submarine, may not sink or render incapable of navigation a merchant vessel without having first placed passengers, crew and ship's papers in a place of safety. For this purpose the ship's boats are not regarded as a place of safety unless the safety of the passengers and crew is assured, in the existing sea and weather conditions, by the proximity of land, or the presence of another vessel which is in a position to take them on board.
The High Contracting Parties invite all other Powers to express their assent to the above rules."
Against that interwar political background it is obvious why nations saw the enemy's naval vessels as the principal target of its own submarines.
Come the 1936 London Treaty submarines were again limited to 2,000 tons and 5.1" guns and replacement at 13 years, but this time with no overall tonnage limit. Japan of course had withdrawn from the Treaty system effective 31 Dec 1936. Germany by the Anglo German Naval Treaty 1935 Article 2(f) was limited to 45% of British submarine tonnage (while staying within the overall 35% limit).
I wouldn't say that the lessons of WW1 were complerely forgotten by the RN inter-war. But with funding restricted it was ASW that came low on the totem pole. When rearmament came from 1936 onwards the priority was on the complex ships that took time to build. Cheap AS vessels could be and were built quickly. But no one expected war in 1939 and no one envisaged the fall of France which increased the U-boat threat for Britain exponentially.
When it came to the Indian Ocean not all sailings were independent. The big troop convoys, including the near monthly WS convoys, were escorted but the main threat was seen as surface raiders.
Convoys were also instituted at different times during periods of increased danger. For example the BC series from Biera Mozambique to Durban S.A..July-Sept 1942 & Aden to Bombay in Nov 1942. Wiki has a list of various IO routes that can then be cross referenced with Convoyweb.
en.m.wikipedia.org
In 1942, there was a shortage of escort vessels in the IO. At times, with the diversion of destroyers to the protection of merchant shipping both there and in the Med, the Eastern Fleet had to remain in harbour at Kilindini.
Convoying however increases shipping demand due to time taken to assemble the ships in the first place and then to disperse them at the end. It also creates bottlenecks in ports suddenly having many ships arrive at the same time. Many of the IO ports already suffered due to the increased volume of wartime traffic.
If you look at the shipping losses in the IO (see U-boat.net link posted previously) most, especially in 1942, were concentrated in the Mozambique Channel between the African coast and Madagascar. Had losses looked like getting too great it would have been a simple task to reroute them East of Madagascar into the wider expanse of the IO. While it might extend journey times, it would make the job of the submarines much harder.