A king will always need a lot of money to do his duty. He needs an army to protect his people. He builds a palace to live like a king. He has to maintain his court. Thus, there is a lot of money involved, but a king should not aim to accumulate money. “He shall not acquire for himself excessive silver and gold”. Again the problem is not the money but the heart. Money can become a god. Mammon, the god of money can enchant your heart, as Jesus says in Matthew 6:24.
17 And he shall not acquire many wives for himself, lest his heart turn away, nor shall he acquire for himself excessive silver and gold.