I think that Pearl is described as a flower so that Hawthorne can talk about her coming out of the "rank luxuriance" of her mother's sin. The metaphor here reminds me of a flower growing out of manure being used for fertilizer. So it's a real statement about something good coming from something very bad.
But why "immortal?" That's a harder question.
To me, we have to ask what is immortal about Pearl. Obviously, her body is not -- she is mortal. So it must be something else. I think that what is immortal is her importance to her mother and (maybe) her intelligence and insight.
If you think about the rest of the book, you can see that Pearl is very important to her mother because she seems to help her emotionally (part of this help comes by way of the comments she makes about the adults -- sort of pushing Hester to see the truth about various things).
So I think that overall the metaphor means that out of Hester's sin has come something that is beautiful, but also something that will be eternally important to her because it will help her redeem herself.