In an action for partition, the court before which the action may be pending may adjudge and determine, as to it shall appear equitable and just, relative to the apportionment of costs among the parties, plaintiff and defendant, by dividing the costs equally or subjecting either party to the payment of the whole or any part thereof.
R.I. Gen. Laws § 34-15-22