When you open the serial monitor, it resets the program and it writes "demetrioAsdsdsdadsd" a second time.
One way to see this is download the example program, pull the card, and read it in your computer before opening the serial monitor.
If you want to eliminate writing in setup before the monitor is opened, you can add these lines after Serial.begin() to wait in the while loop until you enter a character. Then you will read "demetrioAsdsdsdadsd" only once.
Serial.println("Type any character to start");
while (Serial.read() <= 0) {}
What you are seeing is typically a problem with SD demo type programs.
If you want to eliminate writing in setup before the monitor is opened, you can add these lines after Serial.begin() to wait in the while loop until you enter a character. Then you will read "demetrioAsdsdsdadsd" only once.
Or, you can change the mode used to open the file, to include the flag to truncate the file each time it is opened.