It is so so easy to presume in our hindsight history that prophets only knew of what they spoke, but Malachi's perception of his prophetic place is fascinating to consider. Thank you for this question.
Since so many prophetic authors (Isaiah, Jeremiah, Ezekiel, Hosea, Malachi, etc.) preface their words with something similar to "the word/vision of the Lord came to...", they seem to act as an oracle/messenger (as Malachi refers to in the first verse 1) simply, yet faithfully carrying a communique to the recipient. This causes me to believe that Malachi would not withhold information given him about the cessation of prophecy nor presume it without being directly told to seal those words for another time.
Also, with a death sentence awaiting false prophets (Deuteronomy 18:20), it is my opinion that the fear of the Lord with which Malachi and his contemporaries were confronted helped produce these incredible writings in much humility. Humility, in principal, may keep one from believing he is a final messenger and might prevent him from postulating his position. But, as you point out, the ending message sure makes it sound like the next expected voice is that of Elijah's. Clifton D. Gray's book The Historical Background of Malachi seems to lend support to the theory that Malachi may have realized his uniquely latter place.
Read the great prophets of the 8th to the 6th century - Amos, Hosea, Isaiah, Jeremiah, Ezekiel - and then turn to Malachi and instantly "morituri salutamus" seems to echo in every sentence. The very form of discourse - statement, objection "but ye will say," and restatement - recalls the dialectic which soon became prevalent in the schools of the rabbis. The presence of the apocalyptic, so characteristic of the last books to be added to the Old Testament canon, is itself a proof that prophecy can no longer cope with the problem of God's righteousness and a suffering nation...The most striking indication that prophecy is on the wane, however, is found in the unique prediction of a messenger in the person of Elijah, whose duty will be to announce the approaching catastrophe. This is but a confession on the part of prophecy of her inability to inspire another great leader of the people. Her work has been accomplished. And so the writer turns back to the most representative man of the prophetic order, its founder and most conspicuous personality, Elijah, and finds in him the one best fitted to make a last appeal for the conversion of the nation "before the great and terrible day of Yahweh come."