A necessary and sufficient condition for determining prime ideals in any ring?

Definitions

Definition 1. A set $S$ equipped with two binary operations '$+$' and '$\cdot$' will be said to be a pseudo-ring if,

• $(S,+)$ is a monoid

• $(S,\cdot)$ is a semi-group

• $a(b+c)=ab+ac$ and $(b+c)a=bc+ba$ for all $a,b,c\in S$.

Definition 2. A pseudoring $(S,+,\cdot)$ will be said to be a pseudo-integral domain $$ab=0\implies (a=0)\lor (b=0)$$ where $0$ is the identity of the monoid.

Theorem

Let $R$ be a ring and $P$ be an ideal of $R$. Then $P$ is a prime ideal of $R$ iff $(S,+,\cdot)$ is a pseudo-integral domain where, $$S:=\{I+P:I\ \text{is an ideal of}\ R\}$$ and also wehere '$+$' and '$\cdot$' on $S$ are defined as, $$(I+P)+(J+P)=(I+J)+P$$$$(I+P)(J+P)=IJ+P$$

Proof

$\color{red}{\text{Observation 1.}}$ First we need to show that operations on $S$ are indeed well-defined. We will just discuss the well-definedness of '$+$'. The well-definedness of '$\cdot$' follows in almost similar manner.

So, to prove the well-definedness of '$+$' let $I_1+P=I_2+P$ and $J_1+P=J_2+P$ for some $I_1,I_2,J_1,J_2\in S$ (observe that $S\ne\emptyset$ since $P+P\in S$). We need to show that, $$(I_1+P)+(J_1+P)=(I_2+P)+(J_2+P)$$To show this observe that, \begin{align}(i+p_1)+(j+p_2)\in (I_1+P)+(J_1+P)&\implies i+p_1\in I_1+P\land j+p_2\in J_1+P\tag{1}\end{align} Since $I_1+P=I_2+P$ we have $i+p_1\in I_2+P$. Similarly, $j+p_1\in J_2+P$. From this we can easily prove that, $$(i+j)+(p_1+p_2)\in (I_2+J_2)+P\tag{2}$$From $(1)$ and $(2)$ we conclude that, $$(I_1+P)+(J_1+P)\subseteq(I_2+P)+(J_2+P)$$The reverse inclusion can be done in a similar manner. Thus we have shown that '$+$' is indeed well-defined on $S$, the well-definedness of '$\cdot$' can be proved similarly.

$\color{red}{\text{Observation 2.}}$ After showing that the '$+$' and '$\cdot$' of $(S,+,\cdot)$ are indeed well-defined, we observe that $(S,+,\cdot)$ is indeed a pseudo-ring . (The details are straightforward enough and hence is skipped).

After making these two observations we now proceed to prove our theorem. By definition of a prime ideal $P$ in $R$ we know that, $$P\ \text{is prime ideal of R}\iff (IJ\subseteq P\implies I\subseteq P\lor J\subseteq P)$$ where $I,J$ are two ideals of $R$.

Suppose that $P$ is prime in $R$. Then we will show that $S$ is a pseudo-integral domain. By $\color{red}{\text{Observation 2}}$ we can conclude that $S$ is a pseudo-ring so the only thing remaining to show is that if $(I+P)(J+P)=P$ (observe that the additive identity of $S$ is $P$) then either $I+P=P$ or $J+P=P$. Note that, \begin{align}(I+P)(J+P)=P&\implies IJ+P=P\\&\implies IJ\subseteq P\\&\implies (I\subseteq P)\lor (J\subseteq P)\\&\implies (I+P=P)\lor (J+P=P)\end{align} Conversely, let $S$ be a pseudo-integral domain and let $IJ\subseteq P$ we need to show that $I\subseteq P$ or $J\subseteq P$. Observe that, \begin{align}IJ\subseteq P&\implies IJ+P=P\\&\implies (I+P)(J+P)=P\\&\implies (I+P=P)\lor (J+P=P)\\&\implies (I\subseteq P)\lor (J\subseteq P)\end{align}

Question

Is there anything wrong in my theorem or in the proof?

I haven't checked every line (not a big fan of parsing long proofs with lots of symbolic notation) but the undertones ring true.

Before we begin: there is already established terminology for something that is like a ring whose underlying set is an abelian monoid rather than an abelian group: they are called semirings. Since addition of ideals in any ring (and any quotient ring of a ring for that matter) is abelian, you could adopt this terminology instead. The set of ideals of any ring forms a semiring under the usual addition and multiplication of ideals.

There may also be a term for when the monoid is additionally not abelian, but a good subsitute if you don't find one would be "seminearring" or "nearsemiring," considering the definition of nearrings.

I would summarize your idea like this:

$P$ is a prime ideal of $R$ iff the semiring of ideals of $R/P$ has no nonzero zero-divisors.

This follows simply from the following points:

1. The ordinary definition of $P$ prime in $R$ ($xy\in P$ implies $x\in P$ or $y\in P$) is equivalent with the ideal-wise version ($IJ\subseteq P$ implies $I\subseteq P$ or $J\subseteq P$)

2. The ideal-wise sum and product in any ring (in particular, $R/P$) results in a semiring structure. The equivalence in the point above asserts that this semiring has no nonzero zero divisors.