At leaving a server just use the command /exit, it will save your coordinates and will set you these at the next server join