You are probably using an old version of SageMath in CoCalc. The functions inset() and multi_graphics() have been introduced in SageMath 9.0 (released on 1 January 2020). In the menu of the Jupyter notebook, do Kernel -> Change kernel and select "SageMath 9.0".