Prove that every nonempty open subset $G$ of $\mathbb{R}^n$ can be expressed as a countable union of nonoverlapping closed rectangles. Question:

Prove that every nonempty open subset $G$ of $\mathbb{R}^n$ can be expressed as a countable union of nonoverlapping closed rectangles, $G= \bigcup_{k=1}^\infty I_k$.

Attempt:
My idea is to tile $\mathbb{R}^n$ with cubes of side 1. Then discard the cubes that do not intersect with $G$. Then repeat. However, I'm not sure if this is the right approach, since it may only approximate $G$. I also would be unsure of how to formalize such an approach. Alternative ideas would be appreciated.
Here's some additional context since there's quite a bit of discussion on the problem. The problem as originally written in Chapter 2 of Lebesgue Integration on Euclidean Space by Frank Jones reads:

Of course, we need to know what a special rectangle is. This is defined as follows (essentially just a closed rectangle):


The statement is false. A proof by Terence Tao is given in his blog post ‘Covering a non-closed interval by disjoint closed intervals’. To summarize:
Consider the one dimensional case. Suppose $\left\{I_k = \left[a_{k},b_{k}\right]\right\}_{k=1}^{\infty}$ is a collection of disjoint closed intervals such that $\mathbb{R} = \bigcup_{k=1}^{\infty}I_k$. Now consider the set
$$E = \bigcup_{k=1}^{\infty}\left\{a_k,b_k\right\}$$
of endpoints of the intervals. Clearly $E$ is countably infinite. Now $E = \mathbb{R}\setminus \bigcup_{k=1}^{\infty}(a_k,b_k)$, and is thus closed. We claim that $E$ is also perfect. That is $E$ is closed with no isolated points. Let $x \in E$. Then $E$ is either a right end point or a left end point but not both. If it is a right endpoint, then it's easy to see that $x$ is the limit of the left endpoints to the right of $x$. There is a theorem in analysis that says that every perfect subset of a complete metric space is uncountably infinite. Several proofs of this theorem are given here: Proof that a perfect set is uncountable
