Hi Ram,
I hope you are talking about two seperate payment processes-
(a) Using transaction FPY1 to create payments in IDOC format to be sent to bank\payment agencies from SAP for processing and debiting the customer account for utility payments.
(b) Processing the payment order sent by the Banks in the form of IDOCs by creating payment lots and posting them into SAP.
For the first requirement, you are right to state that you have to assign custom FMs against the payment medium format which would create IDOCS that can be sent to Banks.
I would recommend you to create a custom payment medium format for your requirement and create custom FM's by copying from the standard ACH FM's.
You can use the message type FIDCC2 for the purpose of creating the IDOCs.
However, you have to set up an ALE distrbution model and have to to define Bank as a logical system, Create partner profile, Set up and RFC connection etc.
For the Second requirement, you can use the standard program,RBDAPP01 to process the IDOCs of message type (FINSTA).
Hope it helps...
Thanks,
Amlan