Helping myself in the bush

When I was driving back to my home village for a weekend, I stopped on the way in order to have a call of nature in the forest which is located along the highway. In the process of having the call of nature I was arrested by the village militia for committing a crime. They took me to the village office where they told me to either pay a fine of TZS 100,000 or else they would have detained me in the village office till Monday to be taken to Court. Is having a call of nature in the bush an offence?
TW, Moshi

Section 174 of the Public Health Act, 2009 prohibits having a call of nature in areas other than the toilets built for that purpose along the highways. This offence attracts a punishment of a fine amounting to TZS 100,000 or imprisonment for a term of 6 months. Even regulation 10(2)(f) of the Land Transport Regulatory Authority (Certification of Commercial Vehicle Drivers and Registration of Crew) Regulations, 2020 as amended by Government Notice No.81 of 2021 prohibits a public passengers vehicle driver from stopping in the bush where there are no toilets or other social amenities for the purpose of allowing passengers to attend a short call of nature. However the challenge is that there are not enough toilets along highways so one can question what one does when you need to attend to the call of nature.