How to block OS from accessing a directory?

How to block OS from accessing a directory?