Haitham - don’t panic! It’ll be fine. Remember every problem like these has been faced and resolved thousands of times before. Your’s will be too. If you are working in Spain, whether for your own account or for a foreign company, you should be registered and paying both tax and social security. There are two common ways of proceeding in your situation. One is for you to be an employee of the Italian company, one is to register as self-employed and invoice the Italian company as your only client. If your company employs you they have to obtain a fiscal identity number and pay employers’ social security and deduct income tax from your pay. Most companies employ an agency to do this. If you go self-employed there is a slight risk that your arrangement is challenged by the tax authorities who increasingly challenge these arrangements where the “self-employed” person is actually an employee in reality.
If you do just continue as an Italian employee and bank your salary there, you will be operating unofficially here. You won’t be able to bill clients or conduct any other formal business. You could still get a bank account for non-residents using your passport and you should be able to get an EHIC before you leave Italy for your health cover I would have thought.
Hope that helps get you started at least. Good luck.