Responding to the comment left by Gerry Myerson following the original posting:
I totally overlooked that point. Throughout this response, I refer to (for example) $B_1, \cdots, B_k$ as subsets, when I should be referring to them as submultisets.
A good case can be made that this response is defective, because I am not delving that deeply into the OP's (i.e. original poster's) analysis. I found the analysis too difficult to criticize, because I was unable to follow the OP's thinking.
That is, I became confused as to the exact step by step procedure that the OP used to compute (for example) $T(n,2)$ or $T(n,3)$ or $T(n,4)$.
Unfortunately, due to my lack of intuition/experience in this area, the OP's analysis would have had to have been much more long-winded in order for me to analyze the OP's thinking, one slow careful step at a time.
If any other MathSE reviewer can critique the OP's analysis, as is, great. If not, then I would advise the OP to re-write the analysis to make it much more long-winded.
$\color{red}{\text{Edit - Insert}}$
I finally reached the point where I now understand the OP's thinking. Because of how long-winded this answer is, I left a 2nd answer that critiques the OP's work.
Anyway, while the following response is off-point, I will show how I would enumerate $T(n,k).$
For any set $E$, with a finite number of elements, let $|E|$ denote the number of elements in the set $E$.
Let $A(n,k)$ denote the collection of satisfying distributions, under the relaxed restriction that any of the $k$ subsets are permitted to be empty. That is, each element in the collection $A(n,k)$ represents a distribution of the $(2n)$ elements in the set $A$ into $k$ subsets, with the understanding that any of these $k$ subsets are permitted to be empty.
Label the subsets $B_1, B_2, \cdots, B_k.$
For $~m \in \{1,2,\cdots,k\},~$ let $S(n,k,m)$ denote the subset of $A(n,k)$ where each element (i.e. distribution) in $S(n,k,m)$ has subset $B_m$ empty.
Then, it is desired to enumerate
$$|A(n,k)| ~~-~~ |S(n,k,1) \cup S(n,k,2) \cup \cdots \cup S(n,k,k)|.$$
Let $T(0,n,k)$ denote $|A(n,k)|.$
Let $T(1,n,k)$ denote $~\displaystyle \sum_{1 \leq i_1 \leq k} |S(n,k,i_1)|.$
Let $T(2,n,k)$ denote $~\displaystyle \sum_{1 \leq i_1 < i_2 \leq k} |S(n,k,i_1) \cap S(n,k,i_2)|.$
That is, $T(2,n,k)$ denotes the summation of $~\displaystyle \binom{k}{2}~$ terms.
Similarly, for $3 \leq r \leq (k-1),$
let $T(r,n,k)$ denote the summation of the $~\displaystyle \binom{k}{r}~$ terms,
that are given by $~\displaystyle \sum_{1 \leq i_1 < i_2 < \cdots < i_r \leq k} |S(n,k,i_1) \cap S(n,k,i_2) \cap \cdots \cap S(n,k,i_r)|.$
Then, in accordance with Inclusion-Exclusion Theory, the desired enumeration is
$$\sum_{r=0}^{k-1} (-1)^r T(r,n,k).$$
Note that the analogous term $T(k,n,k)$ must equal $0$, because it is impossible for the elements of the set $A$ to be distributed into the $k$ subsets $B_1, \cdots, B_k$, if each of these $k$ subsets is empty.
I should point out that I am assuming (for example) that having $~B_1 = \{a\}, ~B_2 = \{b\}~$ is distinct from having $~B_1 = \{b\}, ~B_2 = \{a\}.$ This distinction is based on the following excerpt from the original posting:
For example, the partition of $\{\{a,a,c\},\{b,b,c\}\}$ of $\{a,a,b,b,c,c\}$ can be defined by an equivalence class or function such as $f(a)=\{1\}$, $f(b)=\{2\}$, $f(c)=\{1,2\}$.
So, the problem has been reduced to the enumeration of $~T(r,n,k).$
$\underline{\text{Enumeration of} ~T(0,n,k)}$
In effect, the multiset $A$ contains the $(2n)$ elements given by
$\{x_1,x_1,x_2,x_2,\cdots,x_n,x_n\}.$
To enumerate $T(0,n,k)$, you have to determine how many of the elements $x_1,x_2,\cdots,x_n$ will be paired with their counterpart into the same subset.
For $v \in \{0,1,2,\cdots,n\}$, assume that $v$ of the elements $x_1,x_2,\cdots,x_n$ will be paired with their counterpart into the same subset.
There are $\displaystyle \binom{n}{v}$ ways of selecting the $v$ elements that will be paired with their counterpart. For each of these $v$ elements, there are then $k$ different subsets that the pair of elements may be assigned to.
So, for a specific (fixed) value of $v$, you have the partial enumeration of
$$\binom{n}{v} \times k^v.$$
Then, there will be $(n - v)$ elements from $x_1,\cdots,x_n$ that are not paired with their counterpart into the same subset. For each of these (separated) pairs of elements, there are $~\displaystyle \binom{k}{2}~$ ways that such a pair can be assigned to two of the $k$ subsets.
So, for a specific (fixed) value of $v$, you have the complete enumeration of
$$\binom{n}{v} \times k^v \times \left[\binom{k}{2}\right]^{(n-v)}.$$
Therefore,
$$T(0,n,k) = \sum_{v=0}^n
\left\{ ~\binom{n}{v} \times k^v \times \left[\binom{k}{2}\right]^{(n-v)} ~\right\}$$
$$ = k^n \sum_{v=0}^n
\left\{ ~\binom{n}{v} \left[\frac{k-1}{2}\right]^{(n-v)} ~\right\}.$$
By binomial expansion, you therefore have that
$$T(0,n,k) = k^n \times \left[1 + \frac{k-1}{2}\right]^n = \left[\frac{k \times (k+1)}{2}\right]^n = \left[\binom{k+1}{2}\right]^n. \tag1 $$
$\underline{\text{Enumeration of} ~T(1,n,k)}$
First, enumerate $|S(n,k,1)|$ which represents the subset of $A(n,k)$ that specifically has $B_1$ empty.
It is immediate that $|S(n,k,1) = |A(n,k-1,0)|$. That is, with the subset $B_1$ required to be empty, all of the elements in $A$ must be distributed into the $~(k-1)~$ subsets $B_2, B_3, \cdots, B_k.$
Further, any satisfying distribution of $A(n,k-1,0)$ that involves the $~(k-1)~$ subsets $B_2,\cdots,B_k$ corresponds to a satisfying distribution in $A(n,k,0)$ with the empty set $B_1$ appended to the other sets $B_2,B_3,\cdots,B_k.$
So, there is a clear bijection between $A(n,k-1,0)$ and $S(n,k,1).$
Further, for reasons of symmetry, it is clear that for any $i_1$ such that $2 \leq i_1 \leq k$, you have that
$|S(n,k,i_1)| = |S(n,k,1)| = |A(n,k-1,0)|.$
So, you have that
$$T(1,n,k) = \binom{n}{1} T(0,n,k-1), \tag2 $$
where the enumeration in (2) above can be completed by applying the formula in (1) above, with the value $k$ adjusted to the value $(k-1).$
$\underline{\text{Enumeration of} ~T(2,n,k)}$
The analysis in this section will be very similar to the analysis in the previous section.
First, enumerate $|S(n,k,1) \cap S(n,k,2)|$ which represents the subset of $A(n,k)$ that specifically has $B_1$ and $B_2$ both empty.
Similar to the analysis in the previous section,
there is a clear bijection between $A(n,k-2,0)$ and $S(n,k,1) \cap S(n,k,2).$
Further, for reasons of symmetry, it is clear that for any $i_1,i_2$ such that $1 \leq i_1 < i_2 \leq k$, you have that
$|S(n,k,i_1) \cap S(n,k,i_2)| = |S(n,k,1) \cap S(n,k,2)| = |A(n,k-2,0)|.$
So, you have that
$$T(2,n,k) = \binom{n}{2} T(0,n,k-2), \tag3 $$
where the enumeration in (3) above can be completed by applying the formula in (1) above, with the value $k$ adjusted to the value $(k-2).$
$\underline{\text{Enumeration of} ~T(m,n,k) ~: ~3 \leq m \leq k-1}$
Again, the analysis in this section will be very similar to the analysis in the previous section.
First, enumerate $|S(n,k,1) \cap S(n,k,2) \cap \cdots \cap S(n,k,m)|$ which represents the subset of $A(n,k)$ that specifically has $B_1, B_2, \cdots, B_m$ all empty.
Similar to the analysis in the previous section,
there is a clear bijection between $A(n,k-m,0)$ and $S(n,k,1) \cap S(n,k,2) \cap \cdots \cap S(n,k,m).$
Further, for reasons of symmetry, it is clear that for any $i_1,i_2, \cdots, i_m$ such that $1 \leq i_1 < i_2 < \cdots < i_m \leq k$, you have that
$|S(n,k,i_1) \cap S(n,k,i_2) \cap \cdots \cap S(n,k,i_m)| = |S(n,k,1) \cap S(n,k,2) \cap \cdots \cap S(n,k,m)| = |A(n,k-m,0)|.$
So, you have that
$$T(m,n,k) = \binom{n}{m} T(0,n,k-m), \tag4 $$
where the enumeration in (4) above can be completed by applying the formula in (1) above, with the value $k$ adjusted to the value $(k-m).$
$\underline{\text{Final Computation of} ~T(n,k)}$
The desired enumeration is
$$T(n,k) = \sum_{r=0}^{k-1} (-1)^r T(r,n,k)$$
Where
$\displaystyle T(0,n,k) = \left[\binom{k+1}{2}\right]^n$
For $1 \leq r \leq k-1$:
$\displaystyle T(r,n,k) = \binom{n}{r} \times \left[\binom{k+1-r}{2}\right]^n.$
$\underline{\text{Sanity Checking The Final Computation}}$
Since my computations disagree with the original poster's, I am going to be slow and careful, in this section.
Suppose that $~n=4$ and $k = 2.$
Then $T(4,2)$ represents the number of different distributions of $\{x_1,x_1,x_2,x_2,x_3,x_3,x_4,x_4\}$ into the subsets $B_1,B_2$, such that neither $B_1,B_2$ are empty.
First, consider $T(0,4,2)$ which allows, $B_1$ or $B_2$ to be empty.
For $v \in \{0,1,2,3,4\}$, consider the subset of distributions that have $v$ of the elements paired with their counterpart.
There are $\displaystyle \binom{4}{v} \times 2^v$ ways of selecting the $v$ pairs and then distributing them among $B_1,B_2$.
Then, for the other $(4-v)$ variables, one of the two components must be given to each of $B_1,B_2$.
So,
$$T(0,4,2) = \sum_{v=0}^4 \binom{4}{v} 2^v = [1 + 2]^4.$$
Clearly, $T(0,4,2) - T(4,2) = 2$, since there are exactly $(2)$ ways that one of the two subsets, $B_1,B_2$ may be empty.
Therefore,
$$T(4,2) = 3^4 - 2.$$
Now, consider the general formula for $T(n,2).$
Then $T(n,2)$ represents the number of different distributions of $\{x_1,x_1,x_2,x_2,\cdots,x_n,x_n\}$ into the subsets $B_1,B_2$, such that neither $B_1,B_2$ are empty.
First, consider $T(0,n,2)$ which allows, $B_1$ or $B_2$ to be empty.
For $v \in \{0,1,2,\cdots,n\}$, consider the subset of distributions that have $v$ of the elements paired with their counterpart.
There are $\displaystyle \binom{n}{v} \times 2^v$ ways of selecting the $v$ pairs and then distributing them among $B_1,B_2$.
Then, for the other $(n-v)$ variables, one of the two components must be given to each of $B_1,B_2$.
So,
$$T(0,n,2) = \sum_{v=0}^n \binom{n}{v} 2^v = [1 + 2]^n.$$
Clearly, $T(0,n,2) - T(n,2) = 2$, since there are exactly $(2)$ ways that one of the two subsets, $B_1,B_2$ may be empty.
Therefore,
$$T(n,2) = 3^n - 2.$$
Here, I don't think that it is a good idea to try to sanity check my results any further with the OP's results. That is, I don't see any way that I have misinterpreted the OP's intent, nor do I see any analytical mistake in my computation of $T(n,2).$
So, some resolution must be found between my $T(n,2)$ computation and the OP's, before further sanity checking can be done.