How to draw boxes and labels around detected objects in android studio form scratch

I have tried many solutions from different internet resources but nothing seems to work.
I have made my android app from scratch in java.
Model is detecting objects correctly.

I have tried many solutions from different internet resources but nothing seems to work.

Have you tried using the google ML Kit - Android for object detection? There is a codelab in Kotlin which explains the whole implementation process and also how to draw the bounding boxes may help you. Thank you!