Car doesn’t start / wobble contact?

Hello, I drive a Fiat 500 0.9 TwinAir Turbo 85 hp and for a week I have had trouble starting the car. It’s not the battery, but a part of what is installed directly in front of the battery (see photo). If I wack it/it moves the position decides whether the central locking/other power supply in the car and starting the engine works. But it also seems to adjust again and again, so that I wrangle about it with almost every start. Unfortunately, I don’t know about cars, what do you call this part? Can you easily replace it yourself? (Doesn’t it seem so difficult for me to replace it?) Thank you in advance!