Not able to understand a backtracking question

in Count NQueens question i dont understand why at line 54
boolean[row][column]= false is done shouldn’t it be done after if block

@Sadaf_khan0107
if(isItsafe((board,row,col)){
board[row][col]=true;
count=count+countNQueens(board,row +1);
board[row][col]=false;
}
if your doubt is regarding this then we use it for backtraking when we place a queen at board[row][col] then we mark it as true indicating that we have place a queen here.
and recursively call the countNQueens function but when we backtrack then we remove the queen placed in board[row][col] by marking it as true.