Mondelez said on Monday that it has ended discussions with Hershey about a possible combination of the two companies.