Walmart says it will raise prices to counter higher costs from President Donald Trump’s tariffs, despite strong quarterly sales.