The reason why I ask is because the switch is for 12V but the circuit of the board runs on 5V. Not sure if the switch would cap it or something.
Also, it should be possible to use it as an on/on switch where the arduino sends a signal to the desktop when the circuit is closed and then it sends a signal again when the circuit is opened, shouldn't it?
The switch will work fine with any voltage up to 12V (and more). But what exactly are you trying to switch with it and how do you expect to connect it to the Arduino?
For the second question the answer is "probably". Subject to the questions above. Plus what desktop and how is it connected to the Arduino? What program in the desktop is going to use the signals sent?
The plan is to close or open the circuit with the switch. If I flip the switch, the arduino sends an input to my desktop via usb. The desktop then interprets closed circuit/open circuit and sends an input in form of a keypress to DCS (a flight simulator).
So I want to use the arduino (and the switches) as an HMD. It doesn't even have to be programmed as an extra button, it's fine if let's say switch up is letter H and switch down is letter G.
If you mean you just want to connect a switch between a pin on the Arduino and ground and then detect when it is opens or closes that's easy enough. You should then be able to send something via serial USB to a PC. Provided you have a program in the PC to interpret it you're there. But I have no idea what any of that has to do with the Arduino being an HMD (I'm guessing Head/Helmet Mounted Display). Where does the "Display" come in?
If you look through the examples in the IDE, e.g.Button, DigitalInputPullup, and some of the Serial ones, that should get you going. If you have trouble getting your program working come back here and someone can probably sort you out but you may need to work out a clearer description of the project.
I'm sorry, my bad. I meant HID as in Human Interface Device. So it's basically a second keyboard because it sends keystrokes. So I could use the box it's in as the ground and then have multiple of those switches, each connected to the box and to an arduino pin. Whenever the circuit is opened/closed, a keyinput is sent like it's described here https://www.arduino.cc/en/Reference/MouseKeyboard .