you pretty much have to if you want to run a company
In many locations that information is intended to be public so that people can find out who they're doing business with at law.
It's possible to form business entities in locations where that information is not freely available to the public, but in doing so you need to understand that people may choose not to do business with an entity which makes no information about itself public.