Mr. Sanders’s speech on Friday also indicated how he might use foreign policy to separate himself from other senators who are running for president: He pointed out that he has voted against all of Mr. Trump’s military budgets, a distinction that Ms. Warren and Ms. Klobuchar cannot claim.