Three coaches of a goods train derailed in Ratlam, Madhya Pradesh, on Thursday night, a railway official confirmed.