Das habe ich aber leider vergessen.
I understand that in English, it is "I am sorry, I forgot it."
Why is Das used?
Why is the word order aber leider used? Will different word orders change the meaning of sentence?
In this case the different word order doesn't change the meaning of the sentence, but its tone.
The most neutral variant would probably be
Aber ich habe das leider vergessen.
This could be translated as
But I forgot that, unfortunately.
By moving the demonstrative pronoun "das" to the front, you're emphasizing it. In that case, it gives
Das habe ich aber leider vergessen.
a little annoyed, somewhat defensive tone: "Yes, I know that we need the thing now. And I know that I was supposed to bring it. But I forgot, ok? Now get off my case already."
In addition to the already excellent anser of Henning I want to answer the question itself and the question from your comments as well: In German language word order is not as strict as in other languages. We don't have to follow SPO all the time to make sentences understandable. But still there are a lot of rules for possible constructs.
The (most) literal English translation of your sentence would be:
But unfortunately I forgot about that.
As you can see from the translation, this sentence is usually not able to stand alone, one would want to know what exactly was forgotten and what the but references to.
As said by Henning the word order gives the emphasis:
As written you would interpret it as
I did some things, but exactly that what you are asking for was forgotten
You could also write:
Ich habe das aber leider vergessen
Here the emphasis lies on Ich and means
It was me who forgot about that, but you (and probably anyone else) obviously remembered.
The third example in your comment is:
Leider habe ich das aber vergessen
The emphasis lies on Leider:
I am so sorry, that I forgot about this
Another variation that best shows the dependency of the other sentence, that is "missing" in your question would be:
Aber leider habe ich das vergessen
Emphasis is on the aber. Here a first sentence like
I know, I should have thought about it, but...
would be expected, and the aber shows, that despite of the fact of the other sentence, something was forgotten.
There is one more (grammatically correct) variation, but you will probably only find this in literature, as usually no one talks like this:
Vergessen habe ich das leider.
You guess: the emphasis is on the verb vergessen...
The "Aber" marks this sentence as an explanation for something else, that occured previously in the communication.
The base sentence is:
Ich habe es leider vergessen. I forgot it, and I'm sorry about it.
As so often, the sentence with "Aber" makes sense in some context only. For example:
Ich wollte eigentlich Kuchen backen. Aber leider habe ich vergessen, Mehl zu kaufen.
Here, the sentence explains why there is no cake, despite there was the intention to bake some. This would, of course, also work without the "aber", since one knows that without flower, one cannot make cake. But this understanding is on the semantic level, whereas the "Aber" tells us on the grammar level that what follows is supposed to explain the failure of something that was mentioned previously. This does not only work with "vergessen", but is very general:
Ich wollte dir Rosen mitbringen, aber der Blumenladen hatte schon zu. Ich hatte gehofft, X würde US Präsident. Es wurde aber stattdessen Y.
Putting Das first like this makes it the topic of the sentence, to use a linguistic term. We can translate it as:
As for that, I'm afraid I forgot it.