There is a network of tracks (list), tracks are of two types - standard (with one start and one end point) and with a fork ( one start and two end points). These points are called nodes. It is known that each track can only be connected to one other track. Thus, each node is connected to at least one other node, with a maximum of three nodes (if this is the starting point of the track with a fork).

Question:
Write a method that determines whether it is possible to delete a specific track, provided that the network should not break.

Would you recommend me ?
Create a new graph object and implementing it in a similar way? ( The graph is not a tree, it has many edges and loops)

It appears you have this up on at least three sites. Two so far have either asked you more questions or closed your question for not being focused.

You also seem to have replied "Implemented the algorithm dfs" but didn't share the code or focused on what has stopped you. I see others downvoting and closing your question so take that as a learning moment and think over why this is happening. Now you can refocus on what has stumped you and ask that question.