Messageboxes are a part of the frontend, and not the backend where django mostly operates.
What you want is javascript and html, a popup messagebox is called a "Modal" and there are several implementations you can use. for example, Bootstrap seems to be popular