It seems to context of your question is the IS-LM model, where your question is specifically about the LM. In the Hicks (IS-LM) view of the money market, the nominal money supply is fixed, as it depends directly on the amount of money printed by the government (although now we tend to think in terms of the central bank) and not on the actions of the other agents of the economy. As such, it is a defining assumption and exogenous to the dynamic of the model.
Now, notice that the real money supply could change when prices move. In the IS-LM context, this could be due to an increase in government spending financed via taxation, where a multiplier higher than one leads to an expansion of aggregate demand and, in the short-run at least, a boom and an increase in the price (assuming a positive sloped aggregate supply).
Now, moving away from such a simplistic assumption, the concept of the money supply is more complex than that. The money supply is usually defined as:
$$M_{s}=\phi B$$
where $\phi$ is the money multiplier and $B$ is the monetary base. A government/central bank can directly alter the the latter by printing money or buying/selling short term debt. It can also affect the multiplier by altering banking regulation like maximum reserve ratios. But, importantly it is the action of bankers and the agents in the economy that determine the value of the multiplier (e.g. via lower lending or more demand for currency, respectively). So, in the end, the money supply does not depend only of the government or central bank agency but of the rest of the agents too.