I found out that using ByteBuf derived from ChannelHandlerContext behaves exactly the same as when using ByteBuf created via Unpooled for example.
That is, both of these two works:
ctx.write(ctx.alloc().buffer().writeBytes("Hello World".getBytes()))
ctx.write(Unpooled.wrappedBuffer("Hello World".getBytes()))
Is there any difference in the behaviour when ByteBuf retrieved from ctx.alloc().buffer() is used versus any other means of creating a BytBuf?