Yes, ... but I wouldn't advance from that position ... to advocating that SIN is of God. particularly when He denies that is true.
I grew up in a family of 8, with an intact Mom/Dad who ran their home quite strictly.
As strict as they were, however, ... they allowed disobedience, ... because, otherwise, ... we would have never survived their parentage.
But, of course, ... they didn't ORDAIN that disobedience, ... they took solid measures to discourage it. But, obedience was not their only goal, ... they also desired to demonstrate and encourage LOVE, and GROWTH.