The UK inflation rate has risen to 2.2%, but this was not as high as economists had forecast.