In C and C++, anything inside " symbols is a string literal. It is constant. Changing it is forbidden. You are not allowed to change it.
cin >> password;
This looks like you're trying to change the string literal. This is not allowed. Even if you could write over the data, this is very silly. You've got enough space for four letters; the letters in the word "test". What happens if the user enters more than four letters? You'd start writing over the next memory locations, and you'd be trashing data.
if (password != mypwd)
This is nonsensical. You are comparing a char-pointer to another char-pointer. Unless they both point to the same place in memory, they will always be different. I suspect you meant to compare what they are actually pointing to.