20 As for you, you meant evil against me, but God meant it for good in order to bring about this present result, to preserve many people alive. (Genesis 50:20)
We see life from only two vantage points which are both limited; the present and the past. We do not have all of the puzzle pieces that God holds to know how He is weaving the tapestry of our lives.
Joseph had endured many years of mistreatment by his family and pretty much everyone else around him. Ultimately, by no cause of his own, he ended up jailed. But throughout he kept his eyes upon the Lord.
Life is a lesson, we learn it when we are done. This old line could never be more true. We see things from such a limited vantage point we cannot be totally clear on what might happen as God unwraps his plan for us. Additionally, we need to be careful that we are staying within His will for our lives and not try to orchestrate every thing.
I have said many times; we plan our plans and God laughs and laughs.
It is so very hard to let go and allow life to proceed as it will. We are creatures of plans and arrangements. But we are typically making these without proper insight. We plan as best we can, but the will of God must be taken into account and there must be room left for Him to work.
Could he just make everything happen, sure. But would we learn from this method? Probably not.