They are the same fish. I'm not 100% sure, but the answer could be the usual AmE versus BrE distinction.
In modern British English, you would only hear the term 'cod'. It's the commonest white fish in the UK and the standard ingredient of classic fish and chips. 'Codfish' may well have been a term used in British English in the past, when the fish was perhaps less common, but it is never used nowadays. Nobody usually says 'codfish' in Britain.
The only contexts where I have come across the term 'codfish' are where the speakers or writers are using American English. Perhaps an AmE speaker could confirm whether 'codfish' is the standard term in the US/Canada or not?