Gianluigi Buffon apologised to the fans after Italy failed to qualify for next year's World Cup in what was his final game for his country.