Instead of taking the decision from the user (of automatically placing the order as COD), Big Basket as a product should present the decision making power to the user and let them decide.
"Hey. Looks like your payment failed. Would you like to go ahead with Cash on Delivery, or try paying online again."
Speaking for myself, I'd try paying online again.