A divorce petition filed under Section 13 A of the Hindu Marriage Act can be converted into a mutual consent divorce which is under Section 13 B of the same act. Some courts have the power of such conversions. You'll just have to produce a joint application or memo mentioning the settlement between the two of you to change the petition to a mutual consent divorce. Usually in a normal mutual consent divorce case, the divorce is granted after six months of application, but you can also produce a memo in the court to waive off the cooling period, if you've lived separately for more than 6 months already.
You can also withdraw the first divorce petition and apply for a fresh mutual consent divorce. In such a case, as mentioned above, the divorce will be granted after six months of cooling period.
Please do consult a local lawyer of this field to learn more about this.
Read more at: https://www.lawyersclubindia.com/experts/procedure-for-converting-divorce-petition-into-mutual-divorce--274191.asp
Hope this helps!