Nouns can serve as adverbs, while retaining their noun meaning. Hence in "lightning fast" lightning is serving as an adverb to the adjective fast, but it does so by bringing its noun meaning to mind - we know that lightning is fast, and hence by picturing lightning, the adverbial intent is conveyed.
When it was first used "brand new" was the same; the audience would picture a brand fresh from the fire, and that would convey how extreme the novelty was, quite vividly.
Heavy use and less familiarity with brands themselves mean that it has lost the vividness it once had, but it is so commonly used as a phrase, that it still exists. If you don't know the imagery (that is, if you don't know why brand was chosen here), then it's no longer a noun used as an adverb, and instead it is just an adverb but only in this context.
Use of nouns as adverbs is common with colours ("fire-engine red", "apple green"). Other cases can be very vivid, but can also fall flat. The same is the case with other words used as parts of speech they don't normally serve.
One of my favourite sentences ever is from a children's book: "The ice thing only dripped and stared, and Ida mad knew goblins had been there." from Maurice Sendak's Outside Over There. Here the adjective mad is used as an adverb to modify the verb knew.
How wonderfully vivid! But do this too often and you will just confuse people. The context of a children's book also allows for rules to be stretched in different ways to other contexts*. Even in this beautiful case, the poetic license has sometimes been "fixed", as I have seen it quoted as "The ice thing only dripped and stared, and Ida mad, knew goblins had been there." where the inserted comma makes it more conventional in its grammar, but robs it of its impact as well as subtly altering the meaning.
As such, be very careful in using this sort of noun-as-adjective construct. To work well the imagery must be immediate, vivid and clear. It must also not clash badly with other imagery used elsewhere in the same piece.
*People often say "you have to understand the rules before you can break them". This is wrong. Truly, you have to understand which rules are actually tools, and how those tools help you, before you can decide that in some cases using those tools differently can help you more. The rules of good writing - even those of grammar which are stricter than those like "favour short, clear sentences" - are an example of those sort of rules, and those who "break" them poetically know not just what they gained by doing so, but have a strong understanding of what they gain in the majority of cases where they follow them.
There's actually a bit of a problem here - the sentence, as provided, without context or a follow-up, is indeed ambiguous.
I'll illustrate first:
They all told me that I couldn't build my dream home by myself; but, I
didn't.
This is how you resolved the sentence, with the meaning that the person built the home but had help - but this isn't the only way to interpret the sentence!
They all told me that I couldn't build my dream home by myself; but, I
didn't.
Here the speaker actually didn't build the house at all. What did they do? Well, they could have grown the house, as in living in some sort of organic structure. They could have found the house of their dreams - perhaps abandoned or lost in some hidden or rarely visited area. They could have also just bought the dream home, and this is actually just a clever add for a real estate agent. Or they could have inherited or been given it, and perhaps this is an ad for one of those lost-property services or a lawyer/estate planning service.
And actually, this isn't the only way to interpret the sentence either!
They all told me that I couldn't build my dream home by myself; but, I
didn't.
Here the speaker is referring to the fact that they themselves didn't build the dream home at all. This could even be combined with emphasis from the previous interpretation for another similar set of interpretations. Maybe their spouse did it, or their kid, or their grandparent - all are very possible introductions to a potentially interesting story.
So, what set of grammatical/syntactic rules are at work? In short: contextual re-interpretation, where ambiguity is resolved with additional information.
The purpose of the sentence is to provide a momentary pause, of confusion, not only because it violates a common template (They said...but I did, or They said...and so I didn't) but also because it is actually ambiguous. No rule leads us to only one interpretation, because it isn't the only valid one. It requires multiple re-readings to get a guess as to what the author might have meant, when no context is available.
Now, you could argue that proximity of "by myself" made the given interpretation more likely, and this is indeed a common enough sentence structure that it's a reasonable heuristic. You could also note that the specificity also made this part of the sentence stand out more, as we assume that all detail in a sentence is necessary for the meaning. For instance:
I told you I didn't want you driving at night; but you did it anyway.
Here we tend to assume that the problem was the "at night", and not the more general "driving" at all, due to both proximity to the objection and due to the specificity. If the speaker objected to driving generally, why did they specify at night? Well, this would also be somewhat ambiguous - because "at night" might have been intended as an intensifier!
Returning to the example sentence, let's look at it again:
They all told me that I couldn't build my dream home by myself; but, I
didn't.
Now, why would "by myself" have been included if it wasn't important to the sentence? If they had said instead:
They all told me that I couldn't build my dream home; but, I didn't.
This is valid, but takes the natural emphasis away due to proximity and reduces our heuristic certainty. It could still be about going it alone, as they could follow with "my spouse and I built it together". But this seems like the less likely intent now.
However, as with my made-up example sentence, what if "by myself" was intended as an intensifier? The speaker was poor or physically disabled, so "they" said that not only could the speaker not build their own dream home, but they thought it was even more absurd that they'd be able to do it by themselves!
Ultimately, there is no syntactic rule that eliminates ambiguity from this sentence simply because there is still ambiguity. Multiple meaning and intentions are possible, and a reading agent can apply heuristic rules to find more or less statistically likely meanings - but no agent would be able to attain certainty.
Best Answer
I strongly suspect that that is was coined as a literal translation of the Latin expression id est (i.e.) with the same meaning, because the construction makes more sense in Latin.
Originally, that is (to say) was used at the beginning of a sentence, where that referred to the previous sentence, or between the two sentences, just like i.e.:
In later use, its position has tended to shift around a bit, but it still refers back to the previous sentence or an idea expressed therein.
Your analysis of it is perfectly fine. You could say it is the subject and the that clause an appositional complement to the subject.
It is of course a fixed idiom, so that the internal structure doesn't matter a great deal any more. Note that it is used in many languages, like French c'etait là que..., Dutch het was daar dat... = "it was there that...".