Milk inflation is not that significant. Five dollars of milk in 2000 will cost you 6.51 USD today[0]. It's actually lower this year than it was in 2014[1].
Milk is also not a necessity for survival. Also over the longer term the UBI would increase at the base inflation rate. It would have to move in relation to all things.