I'm trying, unsuccessfully, to figure it out for a moment now
For N = 8, the chessboard would look like:
Just for reference here is a similar question without the corner restriction and with N = 8 : In how many different ways can we place $8$ identical rooks on a chess board so that no two of them attack each other?

The first observation is that there is exactly one rook on each row. So let us count the number of ways to place rooks on the first and last row. There are $N-2$ squares to choose from and once we place the first rook it takes away exactly one option for the placement of the second rook so there are $(N-2)(N-3)$ choices. Now delete the rows and columns these rooks occupy and we are left to place $N-2$ rooks on a square board of size $N-2$. There are $(N-2)!$ ways to do this (argue this by placing rooks row by row). So in total there are $(N-2)(N-3)[(N-2)!]$ ways to place the rooks.
When N=8, this gives 6*5*(6!) = 21600 ways.