when I put my gear in D my car dont lock

Solution
You mean it won't lock into gear? Or you mean the doors won't lock? If doors, could just be a sensor. If gear, possibly a transmission issue or a shift cable.