Embassies and consulates act as a small sanctuary in a foreign country where you have access to the laws and rights of your home country, representing the interests of the home country abroad.
Not only do embassies and consulates serve as the official diplomatic representation of a foreign government in matters of foreign affairs, they also offer assistance and support to their citizens living or traveling abroad. Consular services include assistance with legal issues, visa renewals, lost passports, and more.