Mr. Brooks is extremely intelligent, highly organized and he is very meticulous about everything that he does. He would not risk his sanity being questioned by others by acknowledging and speaking to Marshall as if he were an actual person.
The conversations that Mr. Brooks and Marshall have are taking place inside the brain of Mr. Brooks. Any other actual person in the same vicinity would not be aware that Mr. Brooks and Marshall are having a conversation at all. Another person might notice Mr. Brooks in somewhat of a daydreaming state, but they wouldn't see him physically talking to Marshall. Mrs. Brooks didn't even realize that the two of them were speaking when he and Marshall actually had a heated and emotional discussion about killing the couple from the dance studio.
Mr. Brooks almost certainly suffers from a form of Dissociative identity disorder. This disorder leads a person to be controlled by another personality living within themselves. While some people cannot control their conversations with this other personality or personalities, Mr. Brooks surely can control his conversations with Marshall, especially while he is around other people.