I seem to recall that the Schubert was not originally a setting of the liturgical Ave Maria but merely shares the name.
You're right: the Schubert song was written as a setting of a poem by Sir Walter Scott.https://en.wikipedia.org/wiki/Ave_Maria_(Schubert)
What we basically have is not different versions of a song but rather entirely different songs that share the same name.
This is the case with a lot of texts that have origins in church.
One needs to keep in mind with sacred music that the range of texts -- particularly in earlier music -- is quite limited.
It is what the composer does with it that is fascinating
They are NOT songs.