The prime minister says he would make no apology for spending money in Wales and Scotland "to improve people's lives".