In any action or proceeding to enforce or modify any provision of a judgment or order entered in an action for divorce, separation, annulment, declaration of nullity of a void marriage, declaration of validity or nullity of a judgement of divorce rendered against a spouse who was the defendant in any action outside the state of New York and did not appear therein where such spouse asserts the nullity of such foreign judgment, or an injunction restraining the prosecution in any other jurisdiction of an action for a divorce, or in any proceeding pursuant to section two hundred forty-three, two hundred forty-four, two hundred forty-five, or two hundred forty-six of this article, the court may in its discretion require either party to pay counsel fees and fees and expenses of experts directly to the attorney of the other party to enable the other party to carry on or defend the action or proceeding as, in the court’s discretion, justice requires having regard to the circumstances of the case and of the respective parties. There shall be a rebuttable presumption that counsel fees shall be awarded to the less monied spouse. In any such action or proceeding, applications for fees and expenses may be maintained by the attorney for the respective parties in counsel’s own name and in counsel’s own behalf. In exercising the court’s discretion, the court shall seek to assure that each party shall be adequately represented and that where fees and expenses are to be awarded, they shall be awarded on a timely basis, pendente lite, so as to enable adequate representation from the commencement of the proceeding. Applications for the award of fees and expenses may be made at any time or times prior to final judgment. Both parties to the action or proceeding and their representative attorneys, shall file an affidavit with the court detailing the financial agreement between the party and the attorney. Such affidavit shall include the amount of any retainer, the amounts paid and still owing thereunder, the hourly amount charged by the attorney, the amounts paid, or to be paid, any experts, and any additional costs, disbursements or expenses. Payment of any retainer fees to the attorney for the petitioning party shall not preclude any awards of fees and expenses to an applicant which would otherwise be allowed under this section.