A Diplomat is a person appointed by a nation state to represent and protect that nation's interests abroad. They form and maintain international relations with regard to issues of war and peace, trade and economics, culture, and human rights. A nations’ diplomats negotiate treaties and international agreements between the respective nations before they are officially endorsed by politicians for passage or accepted by the sending government (depending on political system). Diplomats are members of foreign services and diplomatic corps of various nations of the world.
Diplomats general enjoy immunity in host nations. They are trusted not to violate the laws of the host nation on honor alone and the faith their sending government placed in them. Even in times of war it would be highly unusual for a diplomat to be detained or treated as anything besides an honored guest. This has been a norm between nations since antiquity. When this norm is violated, it is a taboo of with serious ramifications. For example, Iran held 56 American diplomats and consular employees at the US Embassy hostage for 444 in 1979, leading to Iran being ostracized by the west ever since as a “rogue state”.
There is a path for diplomats to obtain permanent resident status in the US through Section 13 of the Immigration and Nationality Act enacted by Congress in 1952. Form I-485 must be submitted with appropriate evidence.