The literature contains answers to your questions, and exploring answers to related questions will lead you to some of the deepest and most beautiful mathematics of the 1990's in algebraic topology. Let me explain ...
Let me start with a general observation. Suppose $H$ is a closed subgroup of a connected Lie group $G$. Then one has a fibration sequence $ G/H \rightarrow BH \xrightarrow{Bi} BG$ and consider the induced map $Bi^*: H^*(BG;k) \rightarrow H^*(BH;k)$. Suppose that, via this map, $H^*(BG;k)$ is a free $H^*(BH;k)$--module. Then one can conclude that $$ H^*(G/H; k) = H^*(BH;k)\otimes_{H^*(BG;k)} k = H^*(BH; k)/(\tilde H^*(BG;k)).$$ (This is an immediate consequence of the Eilenberg--Moore spectral sequence.)
Now let's look at the case when $G$ is a compact Lie group with maximal torus $T$ of rank $r$ and Weyl group $W$, so that $G/T$ is the flag variety. $BT$ is, of course, just $(\mathbb CP^{\infty})^r$, and thus $H^*(BT;k) = k[y_1, \dots, y_r] = k[T^{\vee}]$ for any coefficients $k$. We have maps $$H^*(BG;k) \rightarrow H^*(BT;k)^W \hookrightarrow H^*(BT;k).$$ Miraculously, $H^*(BT;k)^W$ is always polynomial, and $H^*(BT;k)$ is a free module (of rank $|W|$) over this invariant ring. So everything works if $H^*(BG;k) \rightarrow H^*(BT;k)^W$ is an isomorphism.
If $k$ has characteristic $p$, it is known which pairs $(G,p)$ this holds. An easily stated general result: if $p$ does not divide $|W|$, then things work. (The proof is an easy argument using the Becker--Gottlieb transfer.) If I remember right, the general answer might be something like the following: this fails iff $G$ contains elements of order $p$ not conjugate to an element in $T$.
This question is related to the famous Steenrod problem: what polynomial algebras over $k$ can be realized as cohomology of a space. This question was definitively answered at the beginning of the last decade, using the work on `$p$--compact groups' developed by Clarence Wilkerson and Bill Dwyer, which itself built on the work on the Sullivan Conjecture by Haynes Miller, Jean Lannes, and many others. I highly recommend looking up some of these papers. (One can start with the Annals paper of Dwyer and Wilkerson.)