Carlsberg has agreed a wage deal with workers in Denmark, ending a period of strikes that last month saw more than 1,000 staff down tools.