Can't add phone number to contact even when the number is correct

When I try to add a valid Spain fixed phone number to a contact it says that the format is invalid, seems a validation error because I already have contacts with fixed numbers that were added many years ago, now if I try to add the same number that I already have on some contact it says 'Verify the country code and number are correct'. For instance a valid number for Spain would be +34 912345678. I can correctly add Spain mobile phone numbers