Let $R$ be an integral domain that is not a field. Then $R$ contains a nonzero element that is not invertible. For every nonzero element $r$ that is not invertible, $r$ is not a multiple of $r^2$: if it were, then $r=r^2s$ for some $s\in R$. Since $R$ is an integral domain, $1=rs$, contradicting that $r$ is not invertible.
Now, for $I$ any nonzero ideal in $R$, if $I$ equals $R$, then $I$ is only divisible by invertible elements of $R$. By hypothesis, there exists a nonzero, noninvertible element $q$ of $R$, and $I$ is not divisible by $q$. On the other hand, if $I$ does not equal $R$, then $I$ contains a nonzero element $r$ that is not invertible. Thus $r$ is not divisible by $q=r^2$. Since $r$ is not divisible by $q$, also $I$ is not divisible by $q$. Thus, for every nonzero ideal $I$ in $R$, there exists a nonzero, noninvertible element $q$ of $R$ such that $I$ is not divisible by $q$.
Finally, for any free $R$-module $M$, say free on a basis $S$, for every nonzero element $m$ of $M$, the ideal $I$ generated by the finitely many nonzero $S$-coefficients of $m$ is nonzero. Thus there exists a nonzero element $q$ of $R$ such that $I$ is not divisible by $q$. Therefore also $m$ is not divisible by $q$. Therefore, also, for every nonzero $R$-submodule $P$ of $M$, for every nonzero element $m$ of $P$, there exists nonzero, noninvertible $q$ in $R$ such that $m$ is not divisible by $q$. In particular, if $P$ is a direct summand of $M$, then $P$ is not divisible.
Thus, every divisible $R$-module is not projective. In particular, the fraction field of $R$ is divisible. Therefore the fraction field of $R$ is a flat $R$-module that is not projective.