LONDON — Boris Johnson resigned as Britain’s foreign secretary on Monday, becoming the second cabinet minister to quit in less than 24 hours in protest over plans from Prime Minister Theresa May to soften the economic impact of British withdrawal from the European Union.