This could have been asked somewhere else, but I couldn't find it anywhere. Assume $X$ and $Y$ are random variables which take values in $\mathbb{Z}_n$ - i.e., $\{0, 1, 2, ..., n-1\}$. Also assume that $X$ is uniformly distributed. What is the distribution $X+Y$?
My approach: Let $Z$ be a random variable defined by $X+Y$. Then, since the maximum value that $X$ and $Y$ can take is $n-1$, $Z$ can take a maximum number of $2(n-1) = 2n -2$, which means that $Z$ takes values in $\mathbb{Z}_{2n-1}$. Now to get the probability mass function of $Z$, we have that \begin{align*} P(Z = z) &= P(X+Y = z)\\ &= P(X= x, Y = z -x) \\ &= P(X=x) P(Y = z-x) \\ &= \frac{1}{n} P(Y = z - x) \end{align*} which shows that $Z$ has the same distribution as $Y$ and it takes values in $\mathbb{Z}_{2n-1}$. Is my logic correct? If not, how else can I find the distribution of $X+Y$? I would appreciate any help on this!

Taken almost verbatim from here:
I think your issue comes from your third equality, since you have to remember that $$ P(A,B) = P(A|B) P(B), $$ where $P(A|B)$ will equal $P(A)$ only if $A$ and $B$ are independent.
In your case, the probability that $Y=z-x$ is not going to be independent from the probability that $X=x$.The linked chapter from which I copied the quote about convolution has many more details and examples which may be of interest to you.