If you are talking about closing on the sale of your old home which you recently refinanced, then yes I have heard of restrictions that don't allow you to sell within a certain time frame. This restriction was put in place by some lenders to help slow down property flippers.
However, if you are talking about not being able to close on the purchase of your new home, I have never heard of a restriction like that. I personally have refinanced a property I lived in, turned it into a rental, and purchased a new primary residence within a 6 month time frame.
I would start by asking your lender to show you where it says this in the loan documents you signed.