Safe with Display and Buttons

int n1btn, n2btn, n3btn, n4btn, setbtn, clsbtn; //Variablen für Buttons deklarieren
int ln1btn, ln2btn, ln3btn, ln4btn; //Variablen für last Button State

Arrays are your friends, not you enemies.

   while(n1btn==LOW && n2btn==LOW && n3btn==LOW && n4btn==LOW && setbtn==LOW && clsbtn==LOW){
      lcd.setCursor(0,5);
      lcd.print("Hello");
      lcd.setCursor(1,1);
      lcd.print("Press any key");
    }

n1btn, n2btn, n3btn, n4btn, setbtn, and clsbtn are not bound to the digitalRead() function. If all of the switches are not pressed when the Arduino boots up, you will enter this while loop with no way to exit it.

How ARE your switches wired? You are not using the internal pullup resistors, so you must have external resistors. How are they wired?

   while(n1btn==LOW && n2btn==LOW && n3btn==LOW && n4btn==LOW){
      lcd.clear();
      lcd.setCursor(0,0);
      lcd.print("Set password");
    }

Another infinite loop with no way to exit.

You need to scrap this code, and start over. Treat each switch COMPLETELY independently.

There are two parts to your project - setting the initial code and entering the code to re-open the door.

You need to look at the state change detection example, to learn how to detect that a switch HAS BECOME, not IS, pressed.

When you are in the "Enter a new door lock code" mode, each time a switch has become pressed, you record the number of the switch in an array and increment the index into the array. When the 4th switch has been pressed, you exit the "Enter a new door lock code" and enter the "Guess the door combination" mode.

In that mode, each time a switch has become pressed, you record the number of the switch in a different array. When the 4th switch has been pressed, you compare the contents of the two arrays, and open the door, or not, depending on whether the values match, or not.

An oops key and a "shit, I want to start over" key are good things to have. And to handle.