The answer is no. For those who require an explanation. The information is drafted into the Spanish law on the rights or and obligations of foreigners in Spain.
Extract from the Ministry of the Interior.
The Foreigner Identity Card is the unique and exclusive document intended to provide documentation to foreigners in a situation of legal stay in Spain, for which purpose the recipients of the same must complete the actions established for its delivery.
Said Card certifies the legal permanence of foreigners in Spain, *their identification and that the authorisation or recognition of the right to remain in Spanish territory for a period of more than six months has been granted, in accordance with current regulations.
*Please note from the same government site: The holders of the Foreigner Identity Card are obliged to carry said document with them , as well as to display it when required by the Authority or its agents without prejudice to proving their identity through their passport or similar valid document.
The Foreigner Identity Card is personal and non-transferable, the custody and conservation of the document corresponding to its holder. However, children or represented minors who are not emancipated or incapacitated may appear on the Card corresponding to the father, mother or legal representative, if so requested by them, without prejudice to the fact that they may be holders of an independent document.
The foreigner who is in Spanish territory has the right and the obligation to keep, in force, the documentation that proves his identity, issued by the competent authorities of the country of origin or provenance, as well as that which proves his situation in Spain.
Translated extract from the relevant law:
Article 4. Right to documentation.
1. Foreigners who are in Spanish territory have the right and the duty to keep the documentation that proves their identity, issued by the competent authorities of the country of origin or provenance, as well as that which proves their situation in Spain.
In contrast, the DNI for Spanish Nationals.
Concept and validity
The National Identity Document is a public, official, personal and non-transferable document issued by the Ministry of the Interior that enjoys the protection granted by law to public and official documents. Its owner will be obliged to keep it in force and keep it and guard it with due diligence.
Said Document has sufficient value, by itself, to prove the identity and personal data of its owner that are consigned in it, as well as the Spanish nationality of the same.
Likewise, the National Identity Document allows Spaniards of legal age who enjoy full capacity to act and emancipated minors the electronic identification of its holder, as well as to carry out the electronic signature of documents. The electronic signature made through the National Identity Document will have the same value with respect to the data entered in electronic form as the handwritten signature in relation to the data entered on paper.
All Spaniards have the right to be issued the National Identity Document, being mandatory to obtain it by those over fourteen years of age resident in Spain and for those of the same age who, residing abroad, move to Spain for no less to six months. However, it may be obtained before, from the registration of the minor in the Civil Registry.
All persons obliged to obtain the National Identity Document are also required to exhibit it when required to do so by the Authority or its Agents.
He must report his theft or loss as soon as possible to the nearest Police station or post of the Security Forces and Bodies.
The photocopy of the DNI has no value if it is not accompanied by the original.