The question is: why did the English adapt the name pineapple from Spanish (which originally meant pinecone in English) while most European countries eventually adapted the name ananas, which came from the Tupi word nanas (also meaning pineapple).
Possibly relevant to why /z/ won: if I try to pronounce axis with a /z/ instead of an /s/, it sounds hardly at all different. Someone with a better understanding of phonetics can probably explain why the contrast is so small in that context.