Dutch retail giant Ahold has reported a rise in second-quarter profit that failed to meet analysts' expectations, and the company also announced the resignation of its chairman.