The volume-volatility relationship usually ignores possible effects of stock shares. This article proposes a two-phase flow model assuming that capital and stock flows determine stock price and return volatility. Computational simulations suggest that monodirectional capital or stock flows and collective flows exert different effects on stock return volatilities. Considering the impact of stock flows, the positive relationship between capital and return volatility is no longer guaranteed. The inflow of capital and the outflow of stock increase stock price similarly; but exhibit completely different effects on stock return volatilities. A persistent stock inflow (outflow) reduces (intensifies) return volatilities, whereas a monodirectional persistent capital outflow has no such effect. When capital and stock flows' velocities satisfy critical values determined by the initial state of the market, the market enlargement accompanied with increasing stock and capital shows no impact on market stability because of stable return volatilities. Otherwise, stock flows drive return volatilities with stronger effects than capital flows. Further experimental studies that simulate the real stock market through a trading system provide strong evidence supporting the two-phase flow model. Given similar driving forces of capital and stock flows, the interaction of them should be considered in constructing investment strategies and setting policies.