Spawn Minecraft command blocks with already included command?

Ri
1

Is there a possibility, let's say as an example, to spawn a command block via command, but which already contains the command say hi?

Po

/ setblock ~ ~ ~ command_block {Command: "say hi"}