(Update: The example sequence is now real and so the last equation is replaced by (v) and (vi).)
I wonder if it is possible, in the context of ZFC, to give a formal definition for the "sum of the elements of a countable set", such as: $$\sum_{i \in \mathbb{N}} x_i \;.$$
As an exercise, I tried along the following steps.
Let us assume the usual set theoretic definition of natural and real numbers, where $\mathsf{prec}(n) $ denotes the predecessor of the natural $n$, and let $x\,\colon \mathbb{N} \twoheadrightarrow F $ be a surjection (indexed family), where $F\subset \mathbb{R}$. I could then use the following abbreviations:
\begin{alignat*}{3} \text{(i)}\quad & x_i &&\quad\text{for}\quad x(i);\\ % \text{(ii)}\quad & n-1 &&\quad\text{for}\quad \mathsf{prec}(n) ;\\ % \text{(iii)}\quad & \sum_{i=1}^1 x_i &&\quad\text{for}\quad x_1;\\ % \text{(iv)}\quad & \sum_{i=1}^{n} x_i &&\quad\text{for}\quad \left( \sum_{i=1}^{n-1} x_i \right) + x_{n} \wedge n \in \mathbb{N};\\ % \text{(v)}\quad & \sum_{i\in \mathbb{N} } x_i =x &&\quad\text{for}\quad (\exists x \in \mathbb{R})(\forall \varepsilon > \mathbb{R}_{++})\\ % & &&\quad\qquad \left(\exists N \in \mathbb{N} \left(\forall n \in \mathbb{N} \left(n \geq N \rightarrow \left|\sum_{i=1}^n x_i - x\right| < \varepsilon \right)\right)\right);\\ \text{(vi)}\quad & \sum_{i\in \mathbb{N} } x_i = \infty && \quad\text{for}\quad \neg(\sum_{i\in \mathbb{N}} x_i = x). \end{alignat*}
I would like to find a more general definition for the summation in (v). Clearly, some structure is necessary on the set to which each $x_i$ belongs. Here $x_i\in \mathbb{R}$, but is such a complex set necessary? Is there some set "simpler" than $\mathbb{R}$, where countable sums of infinite elements still make sense?
It does not make sense to define sums in the pure set-theoretic context. The notion of a binary operation only makes sense in the study of abstract algebra, when you consider a magma $(S, +)$. In most structures, $(S, +)$ actually forms a monoid, with identity element $0$. It being a monoid means that $0+x=x+0=x$, and that $(x+y)+z=x+(y+z)$. In the context of a monoid, it can be proven that there exists a unique well-defined function $f:S^3\rightarrow{S}$, with $f_3(x,y,z)=(x+y)+z=x+(y+z)$. In an abuse of notation, we typically denote $f_3(x,y,z)$ as $x+y+z$. Now, $(x+y)+z=x+(y+z)$ implies $((w+x)+y)+z=w+(x+(y+z))=w+((x+y)+z)=(w+(x+y))+z=(w+x)+(y+z).$ This implies the existence of a function $f_4:S^4\rightarrow{S}$ that has $f_4(w,x,y,z)$ being denoted as $w+x+y+z$. This can be continued recursively, and this is what allows for the definition of summation with $\Sigma$ notation as you are familiar with.
Technically, we define an $n$-tuple on $S$ as a function $h_n:n\rightarrow{S}$, where $n$ is a natural number defined in the typical set-theoretic fashion, and $\Sigma_{m\in{n}}$ is a function $S^n\rightarrow{S}$, whose input is the function $h_n$ and the output is some $s\in{S}$ such that $s=\Sigma_{m\in{n}}h_n(m)$, and how we define $\Sigma_{m\in{n}}$ is recursively, as follows: we let $\Sigma_{m\in{0}}h_0(m)=0$ for every $h_0\in{S^0}$, and we let $\Sigma_{m\in{\mathsf{succ}(n)}}h_{\mathsf{succ}(n)}(m)=[\Sigma_{m\in{n}}h_n(m)]+h_{\mathsf{succ}(n)}(n)$.
As Thomas Andrews pointed out in the comments to your post, there actually does not exist a satisfactory way to extend this so that we can let $n$ in the symbol $\Sigma_{m\in{n}}$ can be an infinite ordinal, and in many situations, the concept would be completely nonsensical, such as if $(S,+)$ is a finite monoid. This is further complicated by the fact that even if we could do this extension for countable ordinals, the generalizations would still not work for uncountable ordinals, and those extensions generally rely on $(S,+)$ being given an ordering $\leq$ such that $(S,\leq)$ has the least upper bound property, or its dual property with respect to the converse ordering. So the extension you are looking for is not doable with set theory alone. You need order theory, abstract algebra, and even then, it is still not really feasible.